Skip to content

Commit

Permalink
chore: restore struct attributes
Browse files Browse the repository at this point in the history
  • Loading branch information
TomAFrench committed Jun 26, 2024
1 parent 2013e53 commit 01b596b
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions compiler/noirc_frontend/src/node_interner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -628,6 +628,15 @@ impl NodeInterner {
f(value);
}

pub fn update_struct_attributes(
&mut self,
type_id: StructId,
f: impl FnOnce(&mut StructAttributes),
) {
let value = self.struct_attributes.get_mut(&type_id).unwrap();
f(value);
}

pub fn set_type_alias(&mut self, type_id: TypeAliasId, typ: Type, generics: Generics) {
let type_alias_type = &mut self.type_aliases[type_id.0];
type_alias_type.borrow_mut().set_type_and_generics(typ, generics);
Expand Down

0 comments on commit 01b596b

Please sign in to comment.