mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-23 15:23:46 +00:00
13 lines
278 B
Rust
13 lines
278 B
Rust
// Check that `self::foo` is parsed as a general pattern and not a self argument.
|
|
|
|
struct S;
|
|
|
|
impl S {
|
|
fn f(self::S: S) {}
|
|
fn g(&self::S: &S) {}
|
|
fn h(&mut self::S: &mut S) {}
|
|
fn i(&'a self::S: &S) {} //~ ERROR unexpected lifetime `'a` in pattern
|
|
}
|
|
|
|
fn main() {}
|