-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Open
Labels
Description
Julia 1.8.2, Linux
I feel like the behavior of {has,get}{property,field} is a bit suspect when it comes to Modules. The following example should be sufficiently illustrative.
julia> hasproperty(Main, :DataFrames)
false
julia> getproperty(Main, :DataFrames)
DataFrames
julia> hasfield(Main, :DataFrames)
ERROR: MethodError: no method matching hasfield(::Module, ::Symbol)
Closest candidates are:
hasfield(::Type, ::Symbol) at reflection.jl:215
Stacktrace:
[1] top-level scope
@ REPL[26]:1
julia> getfield(Main, :DataFrames)
DataFramesoxinabox, ericphanson and resmaeilbeigiLilithHafner