mirror of
https://github.com/rust-lang/rust.git
synced 2025-09-30 00:03:49 +00:00

also adjust the wording a little so that we don't say "the error occurred here" for two different spans
16 lines
620 B
Plaintext
16 lines
620 B
Plaintext
error[E0080]: evaluation panicked: called `Option::unwrap()` on a `None` value
|
|
--> $DIR/const-unwrap.rs:6:18
|
|
|
|
|
LL | const BAR: i32 = Option::<i32>::None.unwrap();
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ evaluation of `BAR` failed here
|
|
|
|
error[E0080]: evaluation panicked: absolutely not!
|
|
--> $DIR/const-unwrap.rs:9:18
|
|
|
|
|
LL | const BAZ: i32 = Option::<i32>::None.expect("absolutely not!");
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ evaluation of `BAZ` failed here
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
For more information about this error, try `rustc --explain E0080`.
|