And also add it to the symbol.rs list

This commit is contained in:
Marten/Qqwy 2022-06-25 22:39:46 +02:00 committed by Marten/Qqwy
parent a4e1e4e59e
commit 83288ed7da
No known key found for this signature in database
GPG key ID: FACEF83266BDAF72
2 changed files with 8 additions and 7 deletions

View file

@ -1246,6 +1246,7 @@ define_builtins! {
56 LIST_SORT_DESC_COMPARE: "#sortDescCompare"
57 LIST_REPLACE: "replace"
58 LIST_IS_UNIQUE: "#isUnique"
59 LIST_FIND_INDEX: "findIndex"
}
5 RESULT: "Result" => {
0 RESULT_RESULT: "Result" // the Result.Result type alias

View file

@ -2888,7 +2888,7 @@ fn list_find_index() {
r#"
when List.findIndex ["a", "bc", "def"] (\s -> Str.countGraphemes s > 1) is
Ok v -> v
Err _ -> "not found"
Err _ -> 999
"#
),
1,
@ -2904,11 +2904,11 @@ fn list_find_index_not_found() {
r#"
when List.findIndex ["a", "bc", "def"] (\s -> Str.countGraphemes s > 5) is
Ok v -> v
Err _ -> "not found"
Err _ -> 999
"#
),
RocStr::from("not found"),
RocStr
999,
i64
);
}
@ -2920,11 +2920,11 @@ fn list_find_index_empty_typed_list() {
r#"
when List.findIndex [] (\s -> Str.countGraphemes s > 5) is
Ok v -> v
Err _ -> "not found"
Err _ -> 999
"#
),
RocStr::from("not found"),
RocStr
999,
i64
);
}