Skip to content

Commit 3c4fba2

Browse files
mlechuaviatesk
authored andcommitted
Don't produce raw symbol from globalref
This used to implicitly refer to a module-level name, but lowering is now expected to wrap it in a `globalref`. Part of JuliaLang/julia#54772
1 parent 2106c3b commit 3c4fba2

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/eval.jl

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -229,12 +229,7 @@ function to_lowered_expr(mod, ex, ssa_offset=0)
229229
elseif k == K"top"
230230
GlobalRef(Base, Symbol(ex.name_val))
231231
elseif k == K"globalref"
232-
if mod === ex.mod
233-
# Implicitly refers to name in parent module.
234-
Symbol(ex.name_val)
235-
else
236-
GlobalRef(ex.mod, Symbol(ex.name_val))
237-
end
232+
GlobalRef(ex.mod, Symbol(ex.name_val))
238233
elseif k == K"Identifier"
239234
# Implicitly refers to name in parent module
240235
# TODO: Should we even have plain identifiers at this point or should

0 commit comments

Comments
 (0)