JanetDocsPlaygroundI'm feeling luckyGitHub sign in

array/clear



    cfunction
    src/core/array.c on line 344, column 1

    (array/clear arr)

    Empties an array, setting it's count to 0 but does not free the 
    backing capacity. Returns the modified array.


1 exampleSign in to add an example
Loading...
(def a @[23 42])
(array/clear a)
(pp a)
# => prints @[]
pepePlayground