Skip to content

adjust tests for latest Julia master #584

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

Merged
merged 2 commits into from
Aug 25, 2023
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
version:
- '1.6' # LTS
- '1' # current stable
- '1.9-nightly'
- '1.10-nightly'
- 'nightly'
os:
- ubuntu-latest
Expand Down
17 changes: 8 additions & 9 deletions test/interpret.jl
Original file line number Diff line number Diff line change
Expand Up @@ -770,15 +770,10 @@ end
end

@testset "#476 isdefined QuoteNode" begin
f() = !true

@generated function g()
ci = @code_lowered f()
ci.code[1] = Expr(:isdefined, QuoteNode(Float64))
return ci
@eval function issue476()
return $(Expr(:isdefined, QuoteNode(Float64)))
end

@test @interpret(g()) === true
@test (true === @interpret issue476())
end

const override_world = typemax(Csize_t) - 1
Expand Down Expand Up @@ -883,7 +878,11 @@ end
end

ci = code_typed(foo, NTuple{2, Int}; optimize=false)[][1]
mi = Core.Compiler.method_instances(foo, NTuple{2, Int})[]
@static if VERSION ≥ v"1.10.0-DEV.873"
mi = Core.Compiler.method_instances(foo, NTuple{2, Int}, Base.get_world_counter())[]
else
mi = Core.Compiler.method_instances(foo, NTuple{2, Int})[]
end

frameargs = Any[foo, 1, 2]
framecode = JuliaInterpreter.FrameCode(mi.def, ci)
Expand Down
2 changes: 1 addition & 1 deletion test/limits.jl
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ module EvalLimited end
end
modexs = collect(ExprSplitter(EvalLimited, ex))
@static if isdefined(Core, :get_binding_type)
nstmts = 10*12 + 20 # 10 * 12 statements per iteration + α
nstmts = 10*15 + 20 # 10 * 15 statements per iteration + α
else
nstmts = 9*12 + 20 # 10 * 9 statements per iteration + α
end
Expand Down