Ai
21 Star 49 Fork 0

Gitee 极速下载/julia-language

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
此仓库是为了提升国内下载速度的镜像仓库,每日同步一次。 原始仓库: https://github.com/JuliaLang/julia
克隆/下载
coverage_file.jl 570 Bytes
一键复制 编辑 原始数据 按行查看 历史
Jameson Nash 提交于 2024-03-12 00:54 +08:00 . invert linetable representation (#52415)
# This file is a part of Julia. License is MIT: https://julialang.org/license
function code_coverage_test()
if rand(1:2) == 3
return "hello" # never reached
else
r = Int[]
for i = 1:3
push!(r, i)
end
nothing
return r
end
not_reached
end
@eval short_form_func_coverage_test(x) = begin
$(Expr(:line, 1234))
y() = begin
x
end
x * y()
end
success = code_coverage_test() == [1, 2, 3] &&
short_form_func_coverage_test(2) == 4
exit(success ? 0 : 1)
# end of file
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C++
1
https://gitee.com/mirrors/julia-language.git
git@gitee.com:mirrors/julia-language.git
mirrors
julia-language
julia-language
master

搜索帮助