Why is this code an error now? https://play.rust-lang.org/?version=nightly&mode=debug&edition=2018&gist=35bb12de17c51e5eeb6193ae8dfbf40f
And where does the
'static bound come from?
@Zoxc fwiw, this works instead of the existing -- I suspect the closure getting generated for the map perhaps isn't quite accepting enough (e.g., coerces the
'_ to be the same or something?)
let mut a = &mut *this; let p = None.map(|x: u32| a.lower_int());
'static bound comes from how we approximate
for<'a> 'hir: 'a as
'hir: 'static. This specific case is arguably a bug.