Skip to content

Commit

Permalink
adjust tests for latest Julia master (#584)
Browse files Browse the repository at this point in the history
* adjust tests for latest Julia master
* 1.9-nightly to 1.10-night
  • Loading branch information
aviatesk authored Aug 25, 2023
1 parent 910cb6f commit c93dedf
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 deletions.
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

0 comments on commit c93dedf

Please sign in to comment.