Skip to content

Commit

Permalink
Revert "Merge pull request JuliaLang#26139 from JuliaLang/sk/checked-…
Browse files Browse the repository at this point in the history
…out"

This reverts commit b098bdc, reversing
changes made to b1189ce.
  • Loading branch information
KristofferC committed Feb 25, 2018
1 parent 374b9ca commit f76bd98
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 19 deletions.
14 changes: 2 additions & 12 deletions base/loading.jl
Original file line number Diff line number Diff line change
Expand Up @@ -515,8 +515,8 @@ end

function explicit_manifest_deps_get(manifest_file::String, where::UUID, name::String)::Union{Bool,UUID}
open(manifest_file) do io
uuid = deps = nothing
state = :other
uuid = deps = path = nothing
for line in eachline(io)
if contains(line, re_array_of_tables)
uuid == where && break
Expand All @@ -525,8 +525,6 @@ function explicit_manifest_deps_get(manifest_file::String, where::UUID, name::St
elseif state == :stanza
if (m = match(re_uuid_to_string, line)) != nothing
uuid = UUID(m.captures[1])
elseif (m = match(re_path_to_string, line)) != nothing
path = String(m.captures[1])
elseif (m = match(re_deps_to_any, line)) != nothing
deps = String(m.captures[1])
elseif contains(line, re_subsection_deps)
Expand All @@ -541,15 +539,7 @@ function explicit_manifest_deps_get(manifest_file::String, where::UUID, name::St
end
end
uuid == where || return false
if deps == nothing
(state == :deps || path == nothing) && return true
path = abspath(dirname(manifest_file), path)
project_file = env_project_file(path)
project_file isa String &&
return explicit_project_deps_get(project_file, name)
pkg = identify_package(name)
return pkg == nothing || pkg.uuid
end
deps == nothing && return true
# TODO: handle inline table syntax
if deps[1] != '[' || deps[end] != ']'
@warn "Unexpected TOML deps format:\n$deps"
Expand Down
4 changes: 3 additions & 1 deletion test/project/Manifest.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ path = "deps/Foo2.jl"
[[Bar]]
uuid = "2a550a13-6bab-4a91-a4ee-dff34d6b99d0"
path = "deps/Bar"
[Bar.deps]
Baz = "6801f525-dc68-44e8-a4e8-cabd286279e7"
Foo = "6f418443-bd2e-4783-b551-cdbac608adf2"

[[Baz]]
uuid = "6801f525-dc68-44e8-a4e8-cabd286279e7"
Expand All @@ -21,6 +24,5 @@ git-tree-sha1 = "efc7e24c53d6a328011975294a2c75fed2f9800a"
Qux = "b5ec9b9c-e354-47fd-b367-a348bdc8f909"

[[Qux]]
deps = []
uuid = "b5ec9b9c-e354-47fd-b367-a348bdc8f909"
path = "deps/Qux.jl"
6 changes: 0 additions & 6 deletions test/project/deps/Bar/Project.toml

This file was deleted.

0 comments on commit f76bd98

Please sign in to comment.