How to deprecate a change in exported names


if a module used to export a method, and a breaking change is made such that it doesn’t anymore, is there anyway to deprecate it? thanks.



julia> module Foo
           @deprecate exported() Foo.unexported()
           unexported() = println("Not exported")

julia> using Foo

julia> exported()
WARNING: exported() is deprecated, use Foo.unexported() instead.
 [1] depwarn(::String, ::Symbol) at /Applications/
 [2] exported() at ./deprecated.jl:57
 [3] eval(::Module, ::Any) at /Applications/
 [4] eval_user_input(::Any, ::Base.REPL.REPLBackend) at /Applications/
 [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
Not exported