Skip to content

Commit

Permalink
cleaned up import
Browse files Browse the repository at this point in the history
  • Loading branch information
reuvenpo committed Aug 7, 2022
1 parent 701f7f5 commit ff51789
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/module/functions/local_function/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ use crate::ir::*;
use crate::map::{IdHashMap, IdHashSet};
use crate::parse::IndicesToIds;
use crate::{Data, DataId, FunctionBuilder, FunctionId, MemoryId, Module, Result, TypeId, ValType};
use id_arena::Id;
use std::collections::BTreeMap;
use wasmparser::{FuncValidator, Operator, ValidatorResources};

Expand Down Expand Up @@ -106,12 +105,12 @@ impl LocalFunction {
}

/// Iterate over all the blocks in the function
pub fn blocks(&self) -> impl Iterator<Item = (Id<InstrSeq>, &InstrSeq)> {
pub fn blocks(&self) -> impl Iterator<Item = (InstrSeqId, &InstrSeq)> {
self.builder.arena.iter()
}

/// Mutably iterate over all the blocks in the function
pub fn blocks_mut(&mut self) -> impl Iterator<Item = (Id<InstrSeq>, &mut InstrSeq)> {
pub fn blocks_mut(&mut self) -> impl Iterator<Item = (InstrSeqId, &mut InstrSeq)> {
self.builder.arena.iter_mut()
}

Expand Down

0 comments on commit ff51789

Please sign in to comment.