refactor with
This commit is contained in:
@@ -98,7 +98,7 @@ impl<'a, Ctx: DisassemblerContext> Disassembler<'a, Ctx> {
|
||||
self.read_u32();
|
||||
}
|
||||
Builtins => {}
|
||||
ReplBinding | ScopedImportBinding | WithLookup => {
|
||||
ReplBinding | ScopedImportBinding => {
|
||||
self.read_u32();
|
||||
}
|
||||
}
|
||||
@@ -426,16 +426,14 @@ impl<'a, Ctx: DisassemblerContext> Disassembler<'a, Ctx> {
|
||||
let span_id = self.read_u32();
|
||||
("Assert", format!("text_id={} span={}", raw_idx, span_id))
|
||||
}
|
||||
Op::PushWith => {
|
||||
self.read_operand_data();
|
||||
("PushWith", String::new())
|
||||
}
|
||||
Op::PopWith => ("PopWith", String::new()),
|
||||
Op::PrepareWith => ("PrepareWith", String::new()),
|
||||
Op::LookupWith => {
|
||||
let idx = self.read_u32();
|
||||
let name = self.ctx.resolve_string(idx);
|
||||
("LookupWith", format!("{:?}", name))
|
||||
let n = self.read_u8();
|
||||
for _ in 0..n {
|
||||
self.read_operand_data();
|
||||
}
|
||||
("LookupWith", format!("sym={:?} n={}", name, n))
|
||||
}
|
||||
|
||||
Op::LoadBuiltins => ("LoadBuiltins", String::new()),
|
||||
|
||||
Reference in New Issue
Block a user