-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Closed
Labels
bugIndicates an unexpected problem or unintended behaviorIndicates an unexpected problem or unintended behaviordeprecationThis change introduces or involves a deprecationThis change introduces or involves a deprecation
Description
The logic for checking the binding is wrong for constructors so
struct TypeA
function TypeA()
Base.depwarn("blabla", :TypeA)
new()
end
end
julia> TypeA()
WARNING: blabla
Stacktrace:
[1] depwarn(::String, ::Symbol) at ./deprecated.jl:64
[2] TypeA() at ./REPL[6]:3
[3] eval(::Module, ::Any) at ./boot.jl:235
[4] eval_user_input(::Any, ::Base.REPL.REPLBackend) at ./REPL.jl:66
[5] macro expansion at ./REPL.jl:97 [inlined]
[6] (::Base.REPL.##1#2{Base.REPL.REPLBackend})() at ./event.jl:73
while loading no file, in expression starting on line 0
TypeA()
julia> TypeA()
WARNING: blabla
Stacktrace:
[1] depwarn(::String, ::Symbol) at ./deprecated.jl:64
[2] TypeA() at ./REPL[6]:3
[3] eval(::Module, ::Any) at ./boot.jl:235
[4] eval_user_input(::Any, ::Base.REPL.REPLBackend) at ./REPL.jl:66
[5] macro expansion at ./REPL.jl:97 [inlined]
[6] (::Base.REPL.##1#2{Base.REPL.REPLBackend})() at ./event.jl:73
while loading no file, in expression starting on line 0
TypeA()Metadata
Metadata
Assignees
Labels
bugIndicates an unexpected problem or unintended behaviorIndicates an unexpected problem or unintended behaviordeprecationThis change introduces or involves a deprecationThis change introduces or involves a deprecation