File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
src/test/ui/mismatched_types Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 11error[E0379]: functions in traits cannot be declared const
2- --> $DIR/const-fn-in-trait.rs:7 :5
2+ --> $DIR/const-fn-in-trait.rs:5 :5
33 |
44LL | const fn g();
55 | ^^^^^ functions in traits cannot be const
66
77error[E0379]: functions in traits cannot be declared const
8- --> $DIR/const-fn-in-trait.rs:11 :5
8+ --> $DIR/const-fn-in-trait.rs:9 :5
99 |
1010LL | const fn f() -> u32 { 22 }
1111 | ^^^^^ functions in traits cannot be const
Original file line number Diff line number Diff line change 11error[E0053]: method `foo` has an incompatible type for trait
2- --> $DIR/trait-impl-fn-incompatibility.rs:11 :15
2+ --> $DIR/trait-impl-fn-incompatibility.rs:9 :15
33 |
44LL | fn foo(x: u16);
55 | --- type in trait
@@ -11,7 +11,7 @@ LL | fn foo(x: i16) { }
1111 found fn pointer `fn(i16)`
1212
1313error[E0053]: method `bar` has an incompatible type for trait
14- --> $DIR/trait-impl-fn-incompatibility.rs:12 :28
14+ --> $DIR/trait-impl-fn-incompatibility.rs:10 :28
1515 |
1616LL | fn bar(&mut self, bar: &mut Bar);
1717 | -------- type in trait
You can’t perform that action at this time.
0 commit comments