mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-30 15:21:12 +00:00
don't abuse var symbols
This commit is contained in:
parent
9cfadb1b5a
commit
20921f94fb
2 changed files with 13 additions and 12 deletions
|
@ -2042,7 +2042,7 @@ fn dict_get(symbol: Symbol, var_store: &mut VarStore) -> Def {
|
||||||
let arg_dict = Symbol::ARG_1;
|
let arg_dict = Symbol::ARG_1;
|
||||||
let arg_key = Symbol::ARG_2;
|
let arg_key = Symbol::ARG_2;
|
||||||
|
|
||||||
let temp_record = Symbol::ARG_3;
|
let temp_record = Symbol::DICT_GET_RESULT;
|
||||||
|
|
||||||
let bool_var = var_store.fresh();
|
let bool_var = var_store.fresh();
|
||||||
let flag_var = var_store.fresh();
|
let flag_var = var_store.fresh();
|
||||||
|
|
|
@ -912,23 +912,24 @@ define_builtins! {
|
||||||
2 DICT_EMPTY: "empty"
|
2 DICT_EMPTY: "empty"
|
||||||
3 DICT_SINGLETON: "singleton"
|
3 DICT_SINGLETON: "singleton"
|
||||||
4 DICT_GET: "get"
|
4 DICT_GET: "get"
|
||||||
5 DICT_INSERT: "insert"
|
5 DICT_GET_RESULT: "#get_result" // symbol used in the definition of Dict.get
|
||||||
6 DICT_LEN: "len"
|
6 DICT_WALK: "walk"
|
||||||
|
7 DICT_INSERT: "insert"
|
||||||
|
8 DICT_LEN: "len"
|
||||||
|
|
||||||
// This should not be exposed to users, its for testing the
|
// This should not be exposed to users, its for testing the
|
||||||
// hash function ONLY
|
// hash function ONLY
|
||||||
7 DICT_TEST_HASH: "hashTestOnly"
|
9 DICT_TEST_HASH: "hashTestOnly"
|
||||||
|
|
||||||
8 DICT_REMOVE: "remove"
|
10 DICT_REMOVE: "remove"
|
||||||
9 DICT_CONTAINS: "contains"
|
11 DICT_CONTAINS: "contains"
|
||||||
10 DICT_KEYS: "keys"
|
12 DICT_KEYS: "keys"
|
||||||
11 DICT_VALUES: "values"
|
13 DICT_VALUES: "values"
|
||||||
|
|
||||||
12 DICT_UNION: "union"
|
14 DICT_UNION: "union"
|
||||||
13 DICT_INTERSECTION: "intersection"
|
15 DICT_INTERSECTION: "intersection"
|
||||||
14 DICT_DIFFERENCE: "difference"
|
16 DICT_DIFFERENCE: "difference"
|
||||||
|
|
||||||
15 DICT_WALK: "walk"
|
|
||||||
|
|
||||||
}
|
}
|
||||||
7 SET: "Set" => {
|
7 SET: "Set" => {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue