marker icon indicating copy to clipboard operation
marker copied to clipboard

Rustc: Inferred lifetimes are missing from `SynGenericArgs`

Open xFrednet opened this issue 2 years ago • 0 comments

Inferred lifetimes, like the '_ in Cow<'_, str>, are currently not listed in the syntactic representation of generic args, even though it should be. It's probably a bug in MarkerConverterInner::to_lifetime

Code to test in marker_uilints:

use std::borrow::Cow;

// lifetime is missing:
pub fn print_me_cow(_cow: Cow<'_, str>) {}

// named lifetiems are listed:
pub fn print_me_cow<'a>(_cow: Cow<'a, str>) {}

xFrednet avatar Jul 31 '23 19:07 xFrednet