You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: compiler/rustc_mir_build/messages.ftl
+1-1
Original file line number
Diff line number
Diff line change
@@ -265,7 +265,7 @@ mir_build_pointer_pattern = function pointers and raw pointers not derived from
265
265
266
266
mir_build_privately_uninhabited = pattern `{$witness_1}` is currently uninhabited, but this variant contains private fields which may become inhabited in the future
267
267
268
-
mir_build_recursive_default_impl = ..default() in the Default impl does not apply a default for each struct field
268
+
mir_build_recursive_default_impl = calling `..Default::default()` in a `Default` implementation leads to infinite recursion, and does not initialize the fields of a struct or enum
269
269
270
270
mir_build_rust_2024_incompatible_pat = patterns are not allowed to reset the default binding mode in edition 2024
Copy file name to clipboardExpand all lines: tests/ui/lint/lint-unconditional-recursion.stderr
+2-2
Original file line number
Diff line number
Diff line change
@@ -122,7 +122,7 @@ LL | let x = Default::default();
122
122
| ------------------ recursive call site
123
123
|
124
124
= help: a `loop` may express intention better if this is on purpose
125
-
= help: ..default() in the Default impl does not apply a default for each struct field
125
+
= help: calling `..Default::default()` in a `Default` implementation leads to infinite recursion, and does not initialize the fields of a struct or enum
126
126
127
127
error: function cannot return without recursing
128
128
--> $DIR/lint-unconditional-recursion.rs:102:5
@@ -197,7 +197,7 @@ LL | ..Default::default()
197
197
| ------------------ recursive call site
198
198
|
199
199
= help: a `loop` may express intention better if this is on purpose
200
-
= help: ..default() in the Default impl does not apply a default for each struct field
200
+
= help: calling `..Default::default()` in a `Default` implementation leads to infinite recursion, and does not initialize the fields of a struct or enum
0 commit comments