Closed
Description
The following code compiles successfully with no warnings, when it should be producing a deprecation warning.
https://play.rust-lang.org/?gist=aa4c719a14da2bb5cf3ddf8c3066f452&version=stable
The following code compiles successfully with no warnings, when it should be producing a deprecation warning.
https://play.rust-lang.org/?gist=aa4c719a14da2bb5cf3ddf8c3066f452&version=stable
Activity
without-deprecated
feature diesel-rs/diesel#1638abonander commentedon Apr 13, 2018
Some discussion here: #48524 (comment)
Deprecation and stability checking is actually done after macro expansion, so a complete solution would probably need to lift both of those into phase 2. or just have a separate implementation for macros like I did with stability checking in that PR.
cc @petrochenkov
sgrif commentedon Apr 13, 2018
If nothing else,
#[deprecated]
should be giving an error when placed on an item where it has no effect.abonander commentedon Apr 14, 2018
The goal is to support deprecation on macros, it's just that all the infrastructure for deprecation is in a later phase so even a naive implementation would need to redo a lot of the support. We still need stability checking and deprecation after macro expansion as well.
petrochenkov commentedon Jun 22, 2019
Fixed in #62042
Rollup merge of rust-lang#62042 - petrochenkov:macstab, r=matthewjasper
Rollup merge of rust-lang#62042 - petrochenkov:macstab, r=matthewjasper