1 // Regression test for #82126. Checks that mismatched lifetimes and types are
8 struct MarketMultiplier {}
10 impl MarketMultiplier {
11 fn buy(&mut self) -> &mut usize {
16 async fn buy_lock(generator: &Mutex<MarketMultiplier>) -> LockedMarket<'_> {
17 //~^ ERROR this struct takes 0 lifetime arguments but 1 lifetime argument was supplied
18 //~^^ ERROR this struct takes 1 generic argument but 0 generic arguments were supplied
19 LockedMarket(generator.lock().unwrap().buy())
22 struct LockedMarket<T>(T);