Improve documentation for built-in macros#62243
Conversation
|
r? @aidanhs (rust_highfive has picked a reviewer for you, use r? to override) |
|
r? @eddyb |
src/librustc/hir/lowering.rs
Outdated
There was a problem hiding this comment.
Is this needed anymore? The macro_rules! -> macro change would mean !def.legacy is now true.
There was a problem hiding this comment.
No, this is no longer needed (UPD: for libcore, it's still needed for libstd).
src/libstd/macros.rs
Outdated
There was a problem hiding this comment.
Oh, these are unchanged. What needs to happen before these can just be reexports of the libcore ones?
There was a problem hiding this comment.
rustc_builtin_macro stubs acting like the real macros.
#62086 removes the duplicate macros from libstd, but also pub uses their libcore versions from libstd's root (for documentation).
...And stub macros pub used in libstd root break all the dependent crates that inject #[macro_use] extern crate std during rustdoc build.
Alternatively, some doc attribute for selectively documenting private items would also solve the problem (pub use could be replaced with #[doc(force)] use then).
src/libsyntax/feature_gate.rs
Outdated
There was a problem hiding this comment.
Oh, you whitelisted all the existing rustc_* attributes?
|
@bors r+ |
|
📌 Commit c959d7338b3f47bcbdc89f75cdf357c6b3e2f0df has been approved by |
|
☔ The latest upstream changes (presumably #62419) made this pull request unmergeable. Please resolve the merge conflicts. |
|
@bors r=eddyb |
|
📌 Commit 848b2d2 has been approved by |
Ugh, unstable diagnostic output. |
Order in which @bors r=eddyb |
|
📌 Commit 3274507 has been approved by |
Improve documentation for built-in macros This is the `libcore` part of rust-lang#62086. Right now the only effect is improved documentation. The changes in the last few commits are required to make the `libcore` change compile successfully.
Rollup of 6 pull requests Successful merges: - #60081 (Refactor unicode.py script) - #61862 (Make the Weak::{into,as}_raw methods) - #62243 (Improve documentation for built-in macros) - #62422 (Remove some uses of mem::uninitialized) - #62432 (Update rustfmt to 1.3.2) - #62436 (normalize use of backticks/lowercase in compiler messages for librustc_mir) Failed merges: r? @ghost
Improve documentation for built-in macros This is the `libcore` part of rust-lang#62086. Right now the only effect is improved documentation. The changes in the last few commits are required to make the `libcore` change compile successfully.
Rollup of 5 pull requests Successful merges: - #60081 (Refactor unicode.py script) - #61862 (Make the Weak::{into,as}_raw methods) - #62243 (Improve documentation for built-in macros) - #62422 (Remove some uses of mem::uninitialized) - #62436 (normalize use of backticks/lowercase in compiler messages for librustc_mir) Failed merges: r? @ghost
|
@bors r- |
|
@bors retry |
This is the
libcorepart of #62086.Right now the only effect is improved documentation.
The changes in the last few commits are required to make the
libcorechange compile successfully.