We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d3e48d1 commit 81577d3Copy full SHA for 81577d3
src/attributes/type_system.md
@@ -42,7 +42,10 @@ r[attributes.type-system.non_exhaustive.syntax]
42
The `non_exhaustive` attribute uses the [MetaWord] syntax and thus does not take any inputs.
43
44
r[attributes.type-system.non_exhaustive.allowed-positions]
45
-It can be applied to [`struct`s][struct], [`enum`s][enum], and `enum` variants.
+The `non_exhaustive` attribute may only be applied to [`struct`s][struct], [`enum`s][enum], and `enum` variants.
46
+
47
+> [!NOTE]
48
+> `rustc` currently warns in some other positions, but this may be rejected in the future.
49
50
r[attributes.type-system.non_exhaustive.same-crate]
51
Within the defining crate, `non_exhaustive` has no effect.
0 commit comments