mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-29 06:44:46 +00:00
add dropFirst builtin
This commit is contained in:
parent
0fdd8ac1b4
commit
f3a350dd74
4 changed files with 44 additions and 0 deletions
|
@ -979,6 +979,13 @@ pub fn types() -> MutMap<Symbol, (SolvedType, Region)> {
|
|||
Box::new(list_type(flex(TVAR1))),
|
||||
);
|
||||
|
||||
// dropFirst : List elem -> List elem
|
||||
add_top_level_function_type!(
|
||||
Symbol::LIST_DROP_FIRST,
|
||||
vec![list_type(flex(TVAR1))],
|
||||
Box::new(list_type(flex(TVAR1))),
|
||||
);
|
||||
|
||||
// swap : List elem, Nat, Nat -> List elem
|
||||
add_top_level_function_type!(
|
||||
Symbol::LIST_SWAP,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue