'\" t .\" Copyright (c) 2025 Bruce Hill .\" All rights reserved. .\" .TH List.insert_all 3 2025-04-30 "Tomo man-pages" .SH NAME List.insert_all \- add multiple items to a list .SH LIBRARY Tomo Standard Library .SH SYNOPSIS .nf .BI List.insert_all\ :\ func(list:\ @[T],\ items:\ [T],\ at:\ Int\ =\ 0\ ->\ Void) .fi .SH DESCRIPTION Inserts a list of items at a specified position in the list. .SH ARGUMENTS .TS allbox; lb lb lbx lb l l l l. Name Type Description Default list @[T] The mutable reference to the list. - items [T] The items to be inserted. - at Int The index at which to insert the item. 0 .TE .SH RETURN Nothing. .SH NOTES Since indices are 1-indexed and negative indices mean "starting from the back", an index of `0` means "after the last item". .SH EXAMPLES .EX list := [10, 20] list.insert_all([30, 40]) >> list = [10, 20, 30, 40] list.insert_all([99, 100], at=2) >> list = [10, 99, 100, 20, 30, 40] .EE