Skip to content

Commit 4975cae

Browse files
authored
* adjust to JuliaLang/julia#56880 * update to Compiler.jl to v0.0.3
1 parent 0bba93f commit 4975cae

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

Project.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name = "Cthulhu"
22
uuid = "f68482b8-f384-11e8-15f7-abe071a5a75f"
3-
version = "2.16.0"
3+
version = "2.16.1"
44
authors = ["Valentin Churavy <[email protected]> and contributors"]
55

66
[deps]
@@ -19,7 +19,7 @@ WidthLimitedIO = "b8c1c048-cf81-46c6-9da0-18c1d99e41f2"
1919

2020
[compat]
2121
CodeTracking = "0.5, 1"
22-
Compiler = "0.0.2"
22+
Compiler = "0.0.3"
2323
FoldingTrees = "1"
2424
InteractiveUtils = "1.9"
2525
JuliaSyntax = "0.4"

src/interpreter.jl

+9-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,15 @@ function create_cthulhu_source(@nospecialize(opt), effects::Effects)
124124
return OptimizedSource(ir, opt.src, opt.src.inlineable, effects)
125125
end
126126

127-
@static if VERSION v"1.12.0-DEV.734"
127+
@static if VERSION v"1.12.0-DEV.1823"
128+
CC.finishinfer!(state::InferenceState, interp::CthulhuInterpreter) = cthulhu_finish(CC.finishinfer!, state, interp)
129+
function CC.finish!(interp::CthulhuInterpreter, caller::InferenceState)
130+
result = caller.result
131+
result.src = create_cthulhu_source(result.src, result.ipo_effects)
132+
return @invoke CC.finish!(interp::AbstractInterpreter, caller::InferenceState)
133+
end
134+
135+
elseif VERSION v"1.12.0-DEV.734"
128136
CC.finishinfer!(state::InferenceState, interp::CthulhuInterpreter) = cthulhu_finish(CC.finishinfer!, state, interp)
129137
function CC.finish!(interp::CthulhuInterpreter, caller::InferenceState;
130138
can_discard_trees::Bool=false)

0 commit comments

Comments
 (0)