File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -27,7 +27,13 @@ def getIRPhases (env : Environment) (declName : Name) : IRPhases := Id.run do
2727 if !env.header.isModule then
2828 return .all
2929 match env.getModuleIdxFor? declName with
30- | some idx => if isMeta env declName then .comptime else env.header.modules[idx.toNat]?.map (·.irPhases) |>.get!
30+ | some idx => if isMeta env declName then .comptime else
31+ -- HACK: The old compiler gets the ABI wrong if the result is not an immediate
32+ -- constructor. The `match` can be removed once the new compiler is enabled.
33+ match env.header.modules[idx.toNat]?.map (·.irPhases) |>.get! with
34+ | .comptime => .comptime
35+ | .runtime => .runtime
36+ | .all => .all
3137 -- Allow `meta`->non-`meta` acesses in the same module
3238 | none => if isMeta env declName then .comptime else .all
3339
You can’t perform that action at this time.
0 commit comments