News for hackers. Stuff that matters.
Re:Rust: Systems Programming for Everyone by RcouF1uZ4gsC on Saturday August 20, 2016 @01:17PM (#12327441)
The problem is that the pair in the for loop should have a const T as the first parameter. Because it does not have that, you are actually getting a temporary back and storing a pointer to a temporary in selected.

The fix to avoid this is to use auto. If instead of pair, you used auto&& p: map, this would not be an issue

There are no comments on this comment yet.