about summary refs log tree commit diff
path: root/src/test/ui/methods/method-call-err-msg.stderr
blob: 2113add63d61df2b0698c028feb5887c789859f7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
error[E0061]: this function takes 0 parameters but 1 parameter was supplied
  --> $DIR/method-call-err-msg.rs:12:7
   |
LL |     fn zero(self) -> Foo { self }
   |     -------------------- defined here
...
LL |     x.zero(0)   //~ ERROR this function takes 0 parameters but 1 parameter was supplied
   |       ^^^^ expected 0 parameters

error[E0061]: this function takes 1 parameter but 0 parameters were supplied
  --> $DIR/method-call-err-msg.rs:13:7
   |
LL |     fn one(self, _: isize) -> Foo { self }
   |     ----------------------------- defined here
...
LL |      .one()     //~ ERROR this function takes 1 parameter but 0 parameters were supplied
   |       ^^^ expected 1 parameter

error[E0061]: this function takes 2 parameters but 1 parameter was supplied
  --> $DIR/method-call-err-msg.rs:14:7
   |
LL |     fn two(self, _: isize, _: isize) -> Foo { self }
   |     --------------------------------------- defined here
...
LL |      .two(0);   //~ ERROR this function takes 2 parameters but 1 parameter was supplied
   |       ^^^ expected 2 parameters

error[E0599]: no method named `take` found for type `Foo` in the current scope
  --> $DIR/method-call-err-msg.rs:18:7
   |
LL | pub struct Foo;
   | --------------- method `take` not found for this
...
LL |      .take()    //~ ERROR no method named `take` found for type `Foo` in the current scope
   |       ^^^^
   |
   = note: the method `take` exists but the following trait bounds were not satisfied:
           `&mut Foo : std::iter::Iterator`
   = help: items from traits can only be used if the trait is implemented and in scope
   = note: the following traits define an item `take`, perhaps you need to implement one of them:
           candidate #1: `std::io::Read`
           candidate #2: `std::iter::Iterator`

error: aborting due to 4 previous errors

Some errors occurred: E0061, E0599.
For more information about an error, try `rustc --explain E0061`.