Skip to content

Commit c1ee9a3

Browse files
authored
Rollup merge of rust-lang#87183 - RalfJung:option-doctest, r=jyn514
fix typo in compile_fail doctest Fixes a typo introduced by rust-lang#86211. For some reason this typo makes Miri go all crazy when running libcore doctests (rust-lang/miri#1852). Kudos to ``@hyd-dev`` for noticing the typo. Cc ``@tlyu`` ``@joshtriplett``
2 parents 07faa2e + 0d3d6f0 commit c1ee9a3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/core/src/option.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@
356356
//! // must have the same concrete type.
357357
//! fn make_iter(do_insert: bool) -> impl Iterator<Item = i32> {
358358
//! // Explicit returns to illustrate return types not matching
359-
//! match x {
359+
//! match do_insert {
360360
//! true => return (0..4).chain(once(42)).chain(4..8),
361361
//! false => return (0..4).chain(empty()).chain(4..8),
362362
//! }

0 commit comments

Comments
 (0)