From c66a295400d93e37302b5418403d956b58d87d10 Mon Sep 17 00:00:00 2001 From: Shuhei Kadowaki <40514306+aviatesk@users.noreply.github.com> Date: Mon, 21 Dec 2020 18:34:19 +0900 Subject: [PATCH] minor inferrability tweak for `manifest_deps_get` (#38954) --- base/loading.jl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/base/loading.jl b/base/loading.jl index 1cb369f12ccca..cc0cd88a4b123 100644 --- a/base/loading.jl +++ b/base/loading.jl @@ -360,7 +360,8 @@ function project_deps_get(env::String, name::String)::Union{Nothing,PkgId} end function manifest_deps_get(env::String, where::PkgId, name::String)::Union{Nothing,PkgId} - @assert where.uuid !== nothing + uuid = where.uuid + @assert uuid !== nothing project_file = env_project_file(env) if project_file isa String # first check if `where` names the Project itself @@ -371,7 +372,7 @@ function manifest_deps_get(env::String, where::PkgId, name::String)::Union{Nothi return PkgId(pkg_uuid, name) end # look for manifest file and `where` stanza - return explicit_manifest_deps_get(project_file, where.uuid, name) + return explicit_manifest_deps_get(project_file, uuid, name) elseif project_file # if env names a directory, search it return implicit_manifest_deps_get(env, where, name)