10 const Def* stages = world.
annex(annex);
11 auto body = stages->as<
Lam>()->body();
14 auto create_phase = world.
driver().
phase(callee->flags());
15 if (!create_phase) fe::throwf(
"Could not get phase");
17 auto stage = (*create_phase)(world);
19 if (
auto app = body->isa<
App>())
phase->apply(app);
const Def * uncurry_callee() const
auto phase(flags_t flags)
A Phase performs one self-contained task over the whole World.
World & new_world()
Create new Defs into this.
World & old_world()
Get old Defs from here.
friend void swap(Rewriter &rw1, Rewriter &rw2) noexcept
The World represents the whole program and manages creation of MimIR nodes (Defs).
const Driver & driver() const
const Def * annex(Sym sym)
Lookup annex by Sym.
void start() final
Actual entry.
static void run_stage(World &world, flags_t annex)
static consteval flags_t base()