Skip to content

Commit 34b0f94

Browse files
authored
Merge pull request #43 from JunoLab/sp/fixlinenums
fix line numbers
2 parents 5b6910f + 26dab42 commit 34b0f94

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/analysis.jl

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,11 @@ method(c::DynamicCall) = which(c.f, argtypes(c))
2222
method_expr(c::DynamicCall) = method_expr(c.f, argtypes(c))
2323

2424
function code(c::DynamicCall; optimize = false)
25-
codeinfo = code_typed(c.f, argtypes(c), optimize = optimize)
25+
codeinfo = @static if VERSION >= v"1.1.0"
26+
code_typed(c.f, argtypes(c), optimize = optimize, debuginfo=:source)
27+
else
28+
code_typed(c.f, argtypes(c), optimize = optimize)
29+
end
2630
@assert length(codeinfo) == 1
2731
codeinfo = codeinfo[1]
2832
return codeinfo

0 commit comments

Comments
 (0)