<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/compiler/rustc_pattern_analysis/src/errors.rs, branch 1.79.0</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=1.79.0</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=1.79.0'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2024-04-21T07:45:03+00:00</updated>
<entry>
<title>Pass translation closure to add_to_diag_with() as reference</title>
<updated>2024-04-21T07:45:03+00:00</updated>
<author>
<name>Xiretza</name>
<email>xiretza@xiretza.xyz</email>
</author>
<published>2024-04-18T19:18:35+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=5646b65cf58123679fdf4ef489f690d1b21e1436'/>
<id>urn:sha1:5646b65cf58123679fdf4ef489f690d1b21e1436</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Rename `RustcMatchCheckCtxt` -&gt; `RustcPatCtxt`</title>
<updated>2024-03-13T13:07:44+00:00</updated>
<author>
<name>Nadrieril</name>
<email>nadrieril+git@gmail.com</email>
</author>
<published>2024-03-13T13:07:44+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=f27540697e7f17b77dd2fae9fe5d9df8a5eb24c0'/>
<id>urn:sha1:f27540697e7f17b77dd2fae9fe5d9df8a5eb24c0</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Rename `AddToDiagnostic` as `Subdiagnostic`.</title>
<updated>2024-03-10T23:04:49+00:00</updated>
<author>
<name>Nicholas Nethercote</name>
<email>n.nethercote@gmail.com</email>
</author>
<published>2024-03-06T03:00:16+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=541d7cc65c56402f31335e41075838c0da5fbe01'/>
<id>urn:sha1:541d7cc65c56402f31335e41075838c0da5fbe01</id>
<content type='text'>
To match `derive(Subdiagnostic)`.

Also rename `add_to_diagnostic{,_with}` as `add_to_diag{,_with}`.
</content>
</entry>
<entry>
<title>Lint small gaps between ranges</title>
<updated>2024-03-09T00:14:22+00:00</updated>
<author>
<name>Nadrieril</name>
<email>nadrieril+git@gmail.com</email>
</author>
<published>2024-01-14T21:24:10+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=8ac9a04257f73d9861625816d4c741096dd69c67'/>
<id>urn:sha1:8ac9a04257f73d9861625816d4c741096dd69c67</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Rename `SubdiagnosticMessageOp` as `SubdiagMessageOp`.</title>
<updated>2024-03-05T01:14:49+00:00</updated>
<author>
<name>Nicholas Nethercote</name>
<email>n.nethercote@gmail.com</email>
</author>
<published>2024-02-29T05:18:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=573267cf3c10c13f4cb3b9935affd05925d938d0'/>
<id>urn:sha1:573267cf3c10c13f4cb3b9935affd05925d938d0</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Rename `DiagnosticBuilder` as `Diag`.</title>
<updated>2024-02-27T21:55:35+00:00</updated>
<author>
<name>Nicholas Nethercote</name>
<email>n.nethercote@gmail.com</email>
</author>
<published>2024-02-22T23:20:45+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=899cb40809a85eb9d89f6da3268713b83175360a'/>
<id>urn:sha1:899cb40809a85eb9d89f6da3268713b83175360a</id>
<content type='text'>
Much better!

Note that this involves renaming (and updating the value of)
`DIAGNOSTIC_BUILDER` in clippy.
</content>
</entry>
<entry>
<title>Reduce capabilities of `Diagnostic`.</title>
<updated>2024-02-20T02:22:17+00:00</updated>
<author>
<name>Nicholas Nethercote</name>
<email>n.nethercote@gmail.com</email>
</author>
<published>2024-02-06T05:44:30+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=f6f87798439e2ce7861da761b444fe0978335ed9'/>
<id>urn:sha1:f6f87798439e2ce7861da761b444fe0978335ed9</id>
<content type='text'>
Currently many diagnostic modifier methods are available on both
`Diagnostic` and `DiagnosticBuilder`. This commit removes most of them
from `Diagnostic`. To minimize the diff size, it keeps them within
`diagnostic.rs` but changes the surrounding `impl Diagnostic` block to
`impl DiagnosticBuilder`. (I intend to move things around later, to give
a more sensible code layout.)

`Diagnostic` keeps a few methods that it still needs, like `sub`,
`arg`, and `replace_args`.

The `forward!` macro, which defined two additional methods per call
(e.g. `note` and `with_note`), is replaced by the `with_fn!` macro,
which defines one additional method per call (e.g. `with_note`). It's
now also only used when necessary -- not all modifier methods currently
need a `with_*` form. (New ones can be easily added as necessary.)

All this also requires changing `trait AddToDiagnostic` so its methods
take `DiagnosticBuilder` instead of `Diagnostic`, which leads to many
mechanical changes. `SubdiagnosticMessageOp` gains a type parameter `G`.

There are three subdiagnostics -- `DelayedAtWithoutNewline`,
`DelayedAtWithNewline`, and `InvalidFlushedDelayedDiagnosticLevel` --
that are created within the diagnostics machinery and appended to
external diagnostics. These are handled at the `Diagnostic` level, which
means it's now hard to construct them via `derive(Diagnostic)`, so
instead we construct them by hand. This has no effect on what they look
like when printed.

There are lots of new `allow` markers for `untranslatable_diagnostics`
and `diagnostics_outside_of_impl`. This is because
`#[rustc_lint_diagnostics]` annotations were present on the `Diagnostic`
modifier methods, but missing from the `DiagnosticBuilder` modifier
methods. They're now present.
</content>
</entry>
<entry>
<title>Rollup merge of #120734 - nnethercote:SubdiagnosticMessageOp, r=compiler-errors</title>
<updated>2024-02-08T08:06:36+00:00</updated>
<author>
<name>Matthias Krüger</name>
<email>matthias.krueger@famsik.de</email>
</author>
<published>2024-02-08T08:06:36+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=87e1e05aa1185125c4380bc77965b3d50f506c60'/>
<id>urn:sha1:87e1e05aa1185125c4380bc77965b3d50f506c60</id>
<content type='text'>
Add `SubdiagnosticMessageOp` as a trait alias.

It avoids a lot of repetition.

r? matthewjasper
</content>
</entry>
<entry>
<title>Add `SubdiagnosticMessageOp` as a trait alias.</title>
<updated>2024-02-08T02:02:44+00:00</updated>
<author>
<name>Nicholas Nethercote</name>
<email>n.nethercote@gmail.com</email>
</author>
<published>2024-02-06T05:35:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=6b175a848d72f0ea60d80de3bd74d0806a64c40f'/>
<id>urn:sha1:6b175a848d72f0ea60d80de3bd74d0806a64c40f</id>
<content type='text'>
It avoids a lot of repetition.
</content>
</entry>
<entry>
<title>Remove `pattern_arena` from `RustcMatchCheckCtxt`</title>
<updated>2024-01-31T18:25:40+00:00</updated>
<author>
<name>Nadrieril</name>
<email>nadrieril+git@gmail.com</email>
</author>
<published>2024-01-25T03:35:09+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=f65fe3ba59286710324abb9860667f1ecf805df9'/>
<id>urn:sha1:f65fe3ba59286710324abb9860667f1ecf805df9</id>
<content type='text'>
</content>
</entry>
</feed>
