about summary refs log tree commit diff
path: root/tests/ui/ufcs
diff options
context:
space:
mode:
authorMichael Howell <michael@notriddle.com>2023-02-21 14:11:08 -0700
committerMichael Howell <michael@notriddle.com>2023-02-22 08:40:47 -0700
commit3f374128ee3924514aacadf96479e17fee8f9903 (patch)
tree2b0e58a547768a464864cec072eac77be620c1c4 /tests/ui/ufcs
parent3d056c31257cc26760b7e65c5dfdae069f7ddc74 (diff)
downloadrust-3f374128ee3924514aacadf96479e17fee8f9903.tar.gz
rust-3f374128ee3924514aacadf96479e17fee8f9903.zip
diagnostics: update test cases to refer to assoc fn with `self` as method
Diffstat (limited to 'tests/ui/ufcs')
-rw-r--r--tests/ui/ufcs/ufcs-qpath-missing-params.rs2
-rw-r--r--tests/ui/ufcs/ufcs-qpath-missing-params.stderr4
-rw-r--r--tests/ui/ufcs/ufcs-qpath-self-mismatch.stderr4
3 files changed, 5 insertions, 5 deletions
diff --git a/tests/ui/ufcs/ufcs-qpath-missing-params.rs b/tests/ui/ufcs/ufcs-qpath-missing-params.rs
index 766351634bb..a110bec4c0f 100644
--- a/tests/ui/ufcs/ufcs-qpath-missing-params.rs
+++ b/tests/ui/ufcs/ufcs-qpath-missing-params.rs
@@ -15,6 +15,6 @@ fn main() {
       //~^ ERROR missing generics for
 
     <String as IntoCow>::into_cow::<str>("foo".to_string());
-    //~^ ERROR this associated function takes 0 generic arguments but 1
+    //~^ ERROR this method takes 0 generic arguments but 1
     //~| ERROR missing generics for
 }
diff --git a/tests/ui/ufcs/ufcs-qpath-missing-params.stderr b/tests/ui/ufcs/ufcs-qpath-missing-params.stderr
index d0ec47d6132..ace1c36d674 100644
--- a/tests/ui/ufcs/ufcs-qpath-missing-params.stderr
+++ b/tests/ui/ufcs/ufcs-qpath-missing-params.stderr
@@ -30,7 +30,7 @@ help: add missing generic argument
 LL |     <String as IntoCow<B>>::into_cow::<str>("foo".to_string());
    |                       +++
 
-error[E0107]: this associated function takes 0 generic arguments but 1 generic argument was supplied
+error[E0107]: this method takes 0 generic arguments but 1 generic argument was supplied
   --> $DIR/ufcs-qpath-missing-params.rs:17:26
    |
 LL |     <String as IntoCow>::into_cow::<str>("foo".to_string());
@@ -38,7 +38,7 @@ LL |     <String as IntoCow>::into_cow::<str>("foo".to_string());
    |                          |
    |                          expected 0 generic arguments
    |
-note: associated function defined here, with 0 generic parameters
+note: method defined here, with 0 generic parameters
   --> $DIR/ufcs-qpath-missing-params.rs:4:8
    |
 LL |     fn into_cow(self) -> Cow<'a, B>;
diff --git a/tests/ui/ufcs/ufcs-qpath-self-mismatch.stderr b/tests/ui/ufcs/ufcs-qpath-self-mismatch.stderr
index e85144a31ca..96ac4321689 100644
--- a/tests/ui/ufcs/ufcs-qpath-self-mismatch.stderr
+++ b/tests/ui/ufcs/ufcs-qpath-self-mismatch.stderr
@@ -28,7 +28,7 @@ LL |     <i32 as Add<i32>>::add(1u32, 2);
    |     ^^^^^^^^^^^^^^^^^^^^^^^----^^^^
    |                            |
    |                            this argument influences the return type of `Add`
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/core/src/ops/arith.rs:LL:COL
 help: change the type of the numeric literal from `u32` to `i32`
    |
@@ -50,7 +50,7 @@ LL |     <i32 as Add<i32>>::add(1, 2u32);
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^----^
    |                               |
    |                               this argument influences the return type of `Add`
-note: associated function defined here
+note: method defined here
   --> $SRC_DIR/core/src/ops/arith.rs:LL:COL
 help: change the type of the numeric literal from `u32` to `i32`
    |