Skip to content

Commit 78542eb

Browse files
Run FMT over files
1 parent 2278b17 commit 78542eb

File tree

3 files changed

+126
-85
lines changed

3 files changed

+126
-85
lines changed

src/ir.rs

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -374,13 +374,9 @@ impl SymbolTable {
374374
}
375375

376376
pub fn struct_id_from_name(&mut self, name: &str) -> Option<StructId> {
377-
self.structs.iter().find_map(|(id, s)| {
378-
if s.name() == name {
379-
Some(id)
380-
} else {
381-
None
382-
}
383-
})
377+
self.structs
378+
.iter()
379+
.find_map(|(id, s)| if s.name() == name { Some(id) } else { None })
384380
}
385381

386382
pub fn struct_from_struct_id(&mut self, struct_id: StructId) -> &Struct {
@@ -407,7 +403,7 @@ impl Index<SymbolId> for SymbolTable {
407403
fn index(&self, index: SymbolId) -> &Self::Output {
408404
&self.entries[index]
409405
}
410-
}
406+
}
411407

412408
impl Index<&SymbolId> for SymbolTable {
413409
type Output = SymbolTableEntry;

0 commit comments

Comments
 (0)