mirror of
https://github.com/rust-lang/rust.git
synced 2025-11-25 04:07:08 +00:00
These tests specifically test 2015 edition behavior, so ensure that they can only be run with this edition
16 lines
316 B
Rust
16 lines
316 B
Rust
//@ edition: 2015
|
|
|
|
trait Trait {}
|
|
|
|
fn test(_: &for<'a> dyn Trait) {}
|
|
//~^ ERROR `for<...>` expected after `dyn`, not before
|
|
|
|
fn test2(_: for<'a> impl Trait) {}
|
|
//~^ ERROR `for<...>` expected after `impl`, not before
|
|
|
|
// Issue #118564
|
|
type A2 = dyn<for<> dyn>;
|
|
//~^ ERROR expected identifier, found `>`
|
|
|
|
fn main() {}
|