You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
traitStaticTy{typeItem<'a>:'static;}implStaticTyfor(){typeItem<'a> = &'a();//~^ ERROR the type `&'a ()` does not fulfill the required lifetime}fnmain(){}
This code passes with -Ztrait-solver=next in check_type_bounds since we don't normalize the types that show up in type-outlives bounds, so we end up seeing a ty::Alias during process_registered_region_obligations and end up using the item bounds :/
We might need to pass a normalization fn down to process_registered_region_obligations like we do for trait_ref_is_knowable?
The text was updated successfully, but these errors were encountered:
This is because we register the item bounds without actually replacing the self type in check_type_bounds. I don't think we should be replacing the self type, I also don't know what we could do to fix this honestly.
This code passes with
-Ztrait-solver=next
incheck_type_bounds
since we don't normalize the types that show up in type-outlives bounds, so we end up seeing aty::Alias
duringprocess_registered_region_obligations
and end up using the item bounds :/We might need to pass a normalization fn down to
process_registered_region_obligations
like we do fortrait_ref_is_knowable
?The text was updated successfully, but these errors were encountered: