]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-47706.stderr
Rollup merge of #60492 - acrrd:issues/54054_chain, r=SimonSapin
[rust.git] / src / test / ui / issues / issue-47706.stderr
1 error[E0593]: function is expected to take 1 argument, but it takes 2 arguments
2   --> $DIR/issue-47706.rs:11:18
3    |
4 LL |     pub fn new(foo: Option<i32>, _: ()) -> Foo {
5    |     ------------------------------------------ takes 2 arguments
6 ...
7 LL |         self.foo.map(Foo::new)
8    |                  ^^^ expected function that takes 1 argument
9
10 error[E0593]: function is expected to take 0 arguments, but it takes 1 argument
11   --> $DIR/issue-47706.rs:27:5
12    |
13 LL |     Bar(i32),
14    |     -------- takes 1 argument
15 ...
16 LL |     foo(Qux::Bar);
17    |     ^^^ expected function that takes 0 arguments
18    |
19 note: required by `foo`
20   --> $DIR/issue-47706.rs:20:1
21    |
22 LL | / fn foo<F>(f: F)
23 LL | | where
24 LL | |     F: Fn(),
25 LL | | {
26 LL | | }
27    | |_^
28
29 error: aborting due to 2 previous errors
30
31 For more information about this error, try `rustc --explain E0593`.