This commit is contained in:
Eric Newbury 2022-01-21 16:46:47 -05:00
parent c0ea664141
commit 7e7104d9ba
3 changed files with 69 additions and 0 deletions

View file

@ -1302,6 +1302,13 @@ pub fn types() -> MutMap<Symbol, (SolvedType, Region)> {
Box::new(list_type(flex(TVAR1))),
);
// sortDesc : List (Num a) -> List (Num a)
add_top_level_function_type!(
Symbol::LIST_SORT_DESC,
vec![list_type(num_type(flex(TVAR1)))],
Box::new(list_type(num_type(flex(TVAR1))))
);
// find : List elem, (elem -> Bool) -> Result elem [ NotFound ]*
{
let not_found = SolvedType::TagUnion(