mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-28 22:34:45 +00:00
builtins can use builtins now
This commit is contained in:
parent
f7a0fbc8b0
commit
697a65e77c
3 changed files with 85 additions and 79 deletions
|
@ -181,6 +181,17 @@ where
|
|||
references.insert(*symbol);
|
||||
}
|
||||
|
||||
// add any builtins used by other builtins
|
||||
let transitive_builtins: Vec<Symbol> = references
|
||||
.iter()
|
||||
.filter(|s| s.is_builtin())
|
||||
.map(|s| crate::builtins::builtin_dependencies(*s))
|
||||
.flatten()
|
||||
.copied()
|
||||
.collect();
|
||||
|
||||
references.extend(transitive_builtins);
|
||||
|
||||
// NOTE previously we inserted builtin defs into the list of defs here
|
||||
// this is now done later, in file.rs.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue