Skip to content

Commit c34676a

Browse files
Fix E0165 code examples
1 parent 298730e commit c34676a

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/librustc_const_eval/diagnostics.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -384,18 +384,19 @@ let irr = Irrefutable(0);
384384
385385
// This fails to compile because the match is irrefutable.
386386
while let Irrefutable(x) = irr {
387-
...
387+
// ...
388388
}
389+
```
389390
390391
Try this instead:
391392
392-
```
393+
```no_run
393394
struct Irrefutable(i32);
394395
let irr = Irrefutable(0);
395396
396397
loop {
397398
let Irrefutable(x) = irr;
398-
...
399+
// ...
399400
}
400401
```
401402
"##,

0 commit comments

Comments
 (0)