Skip to content

Commit e70cc27

Browse files
committed
Fix a diagnostic
1 parent 9620d26 commit e70cc27

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/librustc_borrowck/diagnostics.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -660,7 +660,7 @@ yield point.
660660
# #![feature(generators, generator_trait)]
661661
# use std::ops::Generator;
662662
let mut b = || {
663-
let a = &3; // <-- This borrow...
663+
let a = &String::new(); // <-- This borrow...
664664
yield (); // ...is still in scope here, when the yield occurs.
665665
println!("{}", a);
666666
};

0 commit comments

Comments
 (0)