Julia: Visibility of `using`ed names in a module

Created on 4 Jul 2020  Â·  1Comment  Â·  Source: JuliaLang/julia

julia> module A
       module B
       f(x) = 1
       end
       using .B: f
       end
Main.A

julia> names(A; all=true, imported=true)
6-element Array{Symbol,1}:
 Symbol("#eval")
 Symbol("#include")
 :A
 :B
 :eval
 :include

Is there a way to discover ~what f refers to inside A~ that A also has a meaning for f? If you change using .B: f to import .B: f, then it's visible.

This appears to be related to a significant performance issue for SymbolServer (which is used by vscode's languageserver indexing machinery), see https://github.com/julia-vscode/SymbolServer.jl/pull/177.

Most helpful comment

>All comments

Was this page helpful?
0 / 5 - 0 ratings