|
| 1 | +error[E0425]: cannot find value `some_fn` in this scope |
| 2 | + --> $DIR/ice-unsized-tuple-const-issue-121443.rs:8:18 |
| 3 | + | |
| 4 | +LL | const TEST: Fn = some_fn; |
| 5 | + | ^^^^^^^ not found in this scope |
| 6 | + |
| 7 | +error[E0277]: the size for values of type `(dyn FnOnce() -> u8 + 'static)` cannot be known at compilation time |
| 8 | + --> $DIR/ice-unsized-tuple-const-issue-121443.rs:8:13 |
| 9 | + | |
| 10 | +LL | const TEST: Fn = some_fn; |
| 11 | + | ^^ doesn't have a size known at compile-time |
| 12 | + | |
| 13 | + = help: the trait `Sized` is not implemented for `(dyn FnOnce() -> u8 + 'static)` |
| 14 | + |
| 15 | +error[E0277]: the size for values of type `(dyn FnOnce() -> u8 + 'static)` cannot be known at compilation time |
| 16 | + --> $DIR/ice-unsized-tuple-const-issue-121443.rs:8:18 |
| 17 | + | |
| 18 | +LL | const TEST: Fn = some_fn; |
| 19 | + | ^^^^^^^ doesn't have a size known at compile-time |
| 20 | + | |
| 21 | + = help: the trait `Sized` is not implemented for `(dyn FnOnce() -> u8 + 'static)` |
| 22 | + = note: constant expressions must have a statically known size |
| 23 | + |
| 24 | +error[E0277]: the size for values of type `(dyn FnOnce() -> u8 + 'static)` cannot be known at compilation time |
| 25 | + --> $DIR/ice-unsized-tuple-const-issue-121443.rs:12:14 |
| 26 | + | |
| 27 | +LL | const TEST2: (Fn, u8) = (TEST, 0); |
| 28 | + | ^^^^^^^^ doesn't have a size known at compile-time |
| 29 | + | |
| 30 | + = help: the trait `Sized` is not implemented for `(dyn FnOnce() -> u8 + 'static)` |
| 31 | + = note: only the last element of a tuple may have a dynamically sized type |
| 32 | + |
| 33 | +error[E0277]: the size for values of type `(dyn FnOnce() -> u8 + 'static)` cannot be known at compilation time |
| 34 | + --> $DIR/ice-unsized-tuple-const-issue-121443.rs:12:25 |
| 35 | + | |
| 36 | +LL | const TEST2: (Fn, u8) = (TEST, 0); |
| 37 | + | ^^^^^^^^^ doesn't have a size known at compile-time |
| 38 | + | |
| 39 | + = help: the trait `Sized` is not implemented for `(dyn FnOnce() -> u8 + 'static)` |
| 40 | + = note: only the last element of a tuple may have a dynamically sized type |
| 41 | + |
| 42 | +error: aborting due to 5 previous errors |
| 43 | + |
| 44 | +Some errors have detailed explanations: E0277, E0425. |
| 45 | +For more information about an error, try `rustc --explain E0277`. |
0 commit comments