add List.releaseExcessCapacity builtin

This commit is contained in:
Brendan Hansknecht 2023-03-13 17:34:18 -07:00
parent 40b50b0091
commit 1319ba4844
No known key found for this signature in database
GPG key ID: 0EA784685083E75B
13 changed files with 177 additions and 3 deletions

View file

@ -35,6 +35,7 @@ pub enum LowLevel {
ListLen,
ListWithCapacity,
ListReserve,
ListReleaseExcessCapacity,
ListAppendUnsafe,
ListGetUnsafe,
ListReplaceUnsafe,
@ -262,6 +263,7 @@ map_symbol_to_lowlevel! {
ListGetCapacity <= LIST_CAPACITY,
ListWithCapacity <= LIST_WITH_CAPACITY,
ListReserve <= LIST_RESERVE,
ListReleaseExcessCapacity <= LIST_RELEASE_EXCESS_CAPACITY,
ListIsUnique <= LIST_IS_UNIQUE,
ListAppendUnsafe <= LIST_APPEND_UNSAFE,
ListPrepend <= LIST_PREPEND,

View file

@ -1410,6 +1410,7 @@ define_builtins! {
78 LIST_WALK_FROM: "walkFrom"
79 LIST_WALK_FROM_UNTIL: "walkFromUntil"
80 LIST_ITER_HELP: "iterHelp"
81 LIST_RELEASE_EXCESS_CAPACITY: "releaseExcessCapacity"
}
7 RESULT: "Result" => {
0 RESULT_RESULT: "Result" exposed_type=true // the Result.Result type alias