about summary refs log tree commit diff
path: root/src/test/ui/invalid-self-argument
AgeCommit message (Collapse)AuthorLines
2023-01-11Move /src/test to /testsAlbert Larsan-48/+0
2020-02-02parser: address review comments re. `self`.Mazdak Farrokhzad-11/+8
2020-02-02parser: move restrictions re. `self` to `ast_validation`.Mazdak Farrokhzad-6/+6
2019-05-25review comments: move back some methods and clean up wordingEsteban Küber-16/+16
2019-05-25Tweak `self` arg not as first argument of a method diagnosticEsteban Küber-6/+12
Mention that `self` is only valid on "associated functions" ``` error: unexpected `self` argument in function --> $DIR/self-in-function-arg.rs:1:15 | LL | fn foo(x:i32, self: i32) -> i32 { self } | ^^^^ not valid as function argument | = note: `self` is only valid as the first argument of an associated function ``` When it is a method, mention it must be first ``` error: unexpected `self` argument in function --> $DIR/trait-fn.rs:4:20 | LL | fn c(foo: u32, self) {} | ^^^^ must be the first associated function argument ```
2018-11-20improve error noteAxary-6/+6
2018-11-16fix tidy (remove whitespace)Axary-0/+24
2018-11-16improve error when self is used as not the first argumentAxary-0/+21