Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support two-argument version of Core.include #863

Merged
merged 1 commit into from
Nov 14, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/lowered.jl
Original file line number Diff line number Diff line change
Expand Up @@ -456,8 +456,10 @@
# path management and parsing new expressions
if length(stmt.args) == 2
add_includes!(methodinfo, mod, @lookup(frame, stmt.args[2]))
elseif length(stmt.args) == 3
add_includes!(methodinfo, @lookup(frame, stmt.args[2]), @lookup(frame, stmt.args[3]))

Check warning on line 460 in src/lowered.jl

View check run for this annotation

Codecov / codecov/patch

src/lowered.jl#L459-L460

Added lines #L459 - L460 were not covered by tests
else
error("include(mapexpr, path) is not supported") # TODO (issue #634)
error("Bad call to Core.include")

Check warning on line 462 in src/lowered.jl

View check run for this annotation

Codecov / codecov/patch

src/lowered.jl#L462

Added line #L462 was not covered by tests
end
assign_this!(frame, nothing) # FIXME: the file might return something different from `nothing`
pc = next_or_nothing!(frame)
Expand All @@ -469,7 +471,7 @@
if isa(mod_or_mapexpr, Module)
add_includes!(methodinfo, mod_or_mapexpr, @lookup(frame, stmt.args[3]))
else
error("include(mapexpr, path) is not supported")
error("include(mapexpr, path) is not supported") # TODO (issue #634)

Check warning on line 474 in src/lowered.jl

View check run for this annotation

Codecov / codecov/patch

src/lowered.jl#L474

Added line #L474 was not covered by tests
end
end
assign_this!(frame, nothing) # FIXME: the file might return something different from `nothing`
Expand Down
Loading