@@ -71,21 +71,19 @@ prelude lookups within that module.
71
71
> Beginning in the 2018 edition, [ use declarations] can reference crates in
72
72
> the extern prelude, so it is considered unidiomatic to use ` extern crate ` .
73
73
74
- > ** Note** : Additional crates that ship with ` rustc ` , such as [ ` proc_macro ` ] ,
75
- > [ ` alloc ` ] , and [ ` test ` ] , are not automatically included with the ` --extern `
76
- > flag when using Cargo. They must be brought into scope with an `extern
77
- > crate` declaration, even in the 2018 edition.
74
+ > ** Note** : Additional crates that ship with ` rustc ` , such as [ ` alloc ` ] , and
75
+ > [ ` test ` ] , are not automatically included with the ` --extern ` flag when using
76
+ > Cargo. They must be brought into scope with an ` extern crate ` declaration,
77
+ > even in the 2018 edition.
78
78
>
79
79
> ``` rust
80
- > extern crate proc_macro ;
81
- > use proc_macro :: TokenStream ;
80
+ > extern crate alloc ;
81
+ > use alloc :: rc :: Rc ;
82
82
> ```
83
83
84
84
<! --
85
- The proc_macro / alloc / test limitation may be lifted if the `-- extern `
86
- flag is stabilized and used . See tracking issue
87
- https : // github.com/rust-lang/rust/issues/57288 and the unstable
88
- `-- extern ` flag added in https : // github.com/rust-lang/rust/pull/54116.
85
+ See https : // github.com/rust-lang/rust/issues/57288 for more about the
86
+ alloc / test limitation .
89
87
- ->
90
88
91
89
## Underscore Imports
@@ -110,6 +108,5 @@ crate to access only its macros.
110
108
[`alloc`]: https: // doc.rust-lang.org/alloc/
111
109
[`no_implicit_prelude`]: modules. md#prelude- items
112
110
[`no_std`]: .. / crates- and- source- files. md#preludes- and- no_std
113
- [`proc_macro`]: https: // doc.rust-lang.org/proc_macro/
114
111
[`test`]: https: // doc.rust-lang.org/test/
115
112
[use declarations]: use - declarations. md
0 commit comments