use more specific function to get symbols/regions

This commit is contained in:
Folkert 2022-04-22 21:40:06 +02:00
parent 6ffe14809f
commit 8720462839
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
2 changed files with 4 additions and 7 deletions

View file

@ -88,10 +88,6 @@ impl Scope {
}
}
pub fn idents(&self) -> impl Iterator<Item = (&Ident, &(Symbol, Region))> {
self.idents.iter()
}
pub fn symbols(&self) -> impl Iterator<Item = (&Symbol, &Region)> {
self.symbols.iter()
}
@ -181,7 +177,8 @@ impl Scope {
opt_defined_alias: Option<Region>,
) -> RuntimeError {
let opaques_in_scope = self
.idents()
.idents
.iter()
.filter(|(_, (sym, _))| {
self.aliases
.get(sym)