Skip to content

Commit 3eb47c5

Browse files
committed
Reflect explicit macro import in reference
1 parent f9f1d2a commit 3eb47c5

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/names/name-resolution.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,6 @@
22

33
> [!NOTE]
44
> This is a placeholder for future expansion.
5+
6+
r[names.name_resolution.ambiguous_panic_imports]
7+
For editions 2024 and earlier the `ambiguous_panic_imports` lint is issued if the import of two builtin macros is ambiguous and they are named `sym::panic`. This can only happen for `core::panic` and `std::panic`.

src/names/preludes.md

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ r[names.preludes.extern.no_std]
8181
### The `no_std` attribute
8282
8383
r[names.preludes.extern.no_std.intro]
84-
The *`no_std` [attribute][attributes]* causes the [`std`] crate to not be linked automatically, the [standard library prelude] to instead use the `core` prelude, and the [`macro_use` prelude] to instead use the macros exported from the `core` crate.
84+
The *`no_std` [attribute][attributes]* causes the [`std`] crate to not be linked automatically and the [standard library prelude] to instead use the `core` prelude.
8585
8686
> [!EXAMPLE]
8787
> <!-- ignore: test infrastructure can't handle no_std -->
@@ -110,9 +110,6 @@ The `no_std` attribute may be used any number of times on a form.
110110
r[names.preludes.extern.no_std.module]
111111
The `no_std` attribute changes the [standard library prelude] to use the `core` prelude instead of the `std` prelude.
112112
113-
r[names.preludes.extern.no_std.macro_use]
114-
By default, all macros exported from the `std` crate are added to the [`macro_use` prelude]. If the `no_std` attribute is specified, then all macros exported from the `core` crate are placed into the [`macro_use` prelude] instead.
115-
116113
r[names.preludes.extern.no_std.edition2018]
117114
> [!EDITION-2018]
118115
> Before the 2018 edition, `std` is injected into the crate root by default. If `no_std` is specified, `core` is injected instead. Starting with the 2018 edition, regardless of `no_std` being specified, neither is injected into the crate root.

0 commit comments

Comments
 (0)