/
githubmirror
/
julia
Обзор
Документация
Войти
/
githubmirror
/
julia
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
test/test_sourcepath.jl
23 строки
601 B
Jameson Nash
task: drop parent and module references (#29483)
05 окт 2018, 23:21
05 окт 2018, 23:21
ea7b1a7
Код
Авторство
О чём код?
# This file is a part of Julia. License is MIT: https://julialang.org/license # source path in tasks path = Base.source_path()::String # this variable is leaked to the source script @test endswith(path, joinpath("test", "test_sourcepath.jl")) @test isabspath(path) @test let ct = current_task() yieldto(@task yieldto(ct, Base.source_path())) end === "" @test let ct = current_task() yieldto(@task schedule(ct, Base.source_path())) end === "" @test let ct = current_task(), t = @task Base.source_path() schedule(ct) yieldto(t) fetch(t) end === "" @test @__FILE__() == path