Erases and deallocate the contents of the List, which becomes an empty list (with a length of 0 elements).
Same as release.
List!(int) list = List!(int).build(1, 2, 3); assert(list.length == 3); list.clear(); assert(list.length == 0);
See Implementation
Erases and deallocate the contents of the List, which becomes an empty list (with a length of 0 elements).
Same as release.