Skip to content

Commit

Permalink
avoid private access to loaded_precompile (#856)
Browse files Browse the repository at this point in the history
* avoid private access to loaded_precompile

* Update loading.jl

* Update src/loading.jl

Co-authored-by: Cody Tapscott <[email protected]>

---------

Co-authored-by: Kristoffer Carlsson <[email protected]>
Co-authored-by: Cody Tapscott <[email protected]>
  • Loading branch information
3 people authored Oct 10, 2024
1 parent 98e1258 commit 336e39c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/loading.jl
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ function parse_pkg_files(id::PkgId)
@assert reqs !== nothing
pkgdata.requirements = reqs
for chi in includes
if isdefined(Base, :loaded_precompiles) && haskey(Base.loaded_precompiles, id => buildid)
if isdefined(Base, :maybe_loaded_precompile) && Base.maybe_loaded_precompile(id, buildid) isa Module
mod = Base.maybe_loaded_precompile(id, buildid)
elseif isdefined(Base, :loaded_precompiles) && haskey(Base.loaded_precompiles, id => buildid)
mod = Base.loaded_precompiles[id => buildid]
else
mod = Base.root_module(id)
Expand Down

0 comments on commit 336e39c

Please sign in to comment.