]> git.lizzy.rs Git - rust.git/blob - src/test/ui/rfc-2632-const-trait-impl/impl-with-default-fn.stderr
Auto merge of #84589 - In-line:zircon-thread-name, r=JohnTitor
[rust.git] / src / test / ui / rfc-2632-const-trait-impl / impl-with-default-fn.stderr
1 error: const trait implementations may not use non-const default functions
2   --> $DIR/impl-with-default-fn.rs:17:1
3    |
4 LL | / impl const Tr for S {
5 LL | |     fn req(&self) {}
6 LL | | }
7    | |_^
8    |
9    = note: `prov` not implemented
10
11 error: const trait implementations may not use non-const default functions
12   --> $DIR/impl-with-default-fn.rs:32:1
13    |
14 LL | / impl const Tr for u32 {
15 LL | |     fn req(&self) {}
16 LL | |     fn default() {}
17 LL | | }
18    | |_^
19    |
20    = note: `prov` not implemented
21
22 error[E0046]: not all trait items implemented, missing: `req`
23   --> $DIR/impl-with-default-fn.rs:26:1
24    |
25 LL |     fn req(&self);
26    |     -------------- `req` from trait
27 ...
28 LL | impl const Tr for u16 {
29    | ^^^^^^^^^^^^^^^^^^^^^ missing `req` in implementation
30
31 error: aborting due to 3 previous errors
32
33 For more information about this error, try `rustc --explain E0046`.