Skip to content

cleaning some "error pattern" text #2520

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 28, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions src/tests/ui.md
Original file line number Diff line number Diff line change
Expand Up @@ -309,8 +309,9 @@ fn main((ؼ

Use `//~?` to match an error without line information.
`//~?` is precise and will not match errors if their line information is available.
For tests wishing to match against compiler diagnostics, error annotations should
be preferred over //@ error-pattern, //@ error-pattern is imprecise and non-exhaustive.
It should be preferred over `//@ error-pattern`
for tests wishing to match against compiler diagnostics,
due to `//@ error-pattern` being imprecise and non-exhaustive.

```rust,ignore
//@ compile-flags: --print yyyy
Expand All @@ -320,8 +321,8 @@ be preferred over //@ error-pattern, //@ error-pattern is imprecise and non-exha

### `error-pattern`

The `error-pattern` [directive](directives.md) can be used for runtime messages, which don't
have a specific span, or in exceptional cases, for compile time messages.
The `error-pattern` [directive](directives.md) can be used for runtime messages which don't
have a specific span, or, in exceptional cases, for compile time messages.

Let's think about this test:

Expand Down