rust/tests/rustdoc-ui/issues/issue-81662-shortness.rs
Esteban Küber 1bbaf6eb2f On short error format, append primary span label to message
The `error-format=short` output only displays the path, error code and
main error message all in the same line. We now add the primary span label
as well after the error message, to provide more context.
2024-08-06 04:08:10 +00:00

14 lines
347 B
Rust

//@ compile-flags:--test --error-format=short
//@ check-stdout
//@ error-pattern:cannot find function `foo`
//@ normalize-stdout-test: "tests/rustdoc-ui/issues" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101
/// ```rust
/// foo();
/// ```
fn foo() {
println!("Hello, world!");
}