<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/compiler/rustc_errors/src/markdown/tests, branch master</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=master</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=master'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2024-07-28T22:26:52+00:00</updated>
<entry>
<title>Reformat `use` declarations.</title>
<updated>2024-07-28T22:26:52+00:00</updated>
<author>
<name>Nicholas Nethercote</name>
<email>n.nethercote@gmail.com</email>
</author>
<published>2024-07-28T22:13:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=84ac80f1921afc243d71fd0caaa4f2838c294102'/>
<id>urn:sha1:84ac80f1921afc243d71fd0caaa4f2838c294102</id>
<content type='text'>
The previous commit updated `rustfmt.toml` appropriately. This commit is
the outcome of running `x fmt --all` with the new formatting options.
</content>
</entry>
<entry>
<title>Support lists and stylings in more places for `rustc --explain`</title>
<updated>2024-07-10T13:41:36+00:00</updated>
<author>
<name>Alex Macleod</name>
<email>alex@macleod.io</email>
</author>
<published>2024-06-26T14:02:52+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=5824ab178b0b28c948798576de78625ba8209adc'/>
<id>urn:sha1:5824ab178b0b28c948798576de78625ba8209adc</id>
<content type='text'>
</content>
</entry>
<entry>
<title>apply fmt</title>
<updated>2024-01-11T12:04:48+00:00</updated>
<author>
<name>klensy</name>
<email>klensy@users.noreply.github.com</email>
</author>
<published>2024-01-11T12:04:48+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=aa696c5a228a2c9730227eb5a0e99fb9d85eb61d'/>
<id>urn:sha1:aa696c5a228a2c9730227eb5a0e99fb9d85eb61d</id>
<content type='text'>
</content>
</entry>
<entry>
<title>remove redundant imports</title>
<updated>2023-12-10T02:56:22+00:00</updated>
<author>
<name>surechen</name>
<email>chenshuo17@huawei.com</email>
</author>
<published>2023-11-10T02:11:24+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=40ae34194c586eea3614d3216322053d2e8e7b37'/>
<id>urn:sha1:40ae34194c586eea3614d3216322053d2e8e7b37</id>
<content type='text'>
detects redundant imports that can be eliminated.

for #117772 :

In order to facilitate review and modification, split the checking code and
removing redundant imports code into two PR.
</content>
</entry>
<entry>
<title>Unite bless environment variables under `RUSTC_BLESS`</title>
<updated>2023-07-26T20:54:02+00:00</updated>
<author>
<name>Trevor Gross</name>
<email>tmgross@umich.edu</email>
</author>
<published>2023-07-03T17:40:14+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=9439e02fb2332d6ffed6a61f95923204faa82655'/>
<id>urn:sha1:9439e02fb2332d6ffed6a61f95923204faa82655</id>
<content type='text'>
Currently, Clippy, Miri, Rustfmt, and rustc all use an environment variable to
indicate that output should be blessed, but they use different variable names.
In order to improve consistency, this patch applies the following changes:

- Emit `RUSTC_BLESS` within `prepare_cargo_test` so it is always
  available
- Change usage of `MIRI_BLESS` in the Miri subtree to use `RUSTC_BLESS`
- Change usage of `BLESS` in the Clippy subtree to `RUSTC_BLESS`
- Change usage of `BLESS` in the Rustfmt subtree to `RUSTC_BLESS`
- Adjust the blessable test in `rustc_errors` to use this same
  convention
- Update documentation where applicable

Any tools that uses `RUSTC_BLESS` should check that it is set to any value
other than `"0"`.
</content>
</entry>
<entry>
<title>Add a simple markdown parser for formatting `rustc --explain`</title>
<updated>2023-07-03T20:04:18+00:00</updated>
<author>
<name>Trevor Gross</name>
<email>tmgross@umich.edu</email>
</author>
<published>2022-12-19T18:09:40+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=6a1c10bd85442f52f1d55d51005481cfa5cb40b5'/>
<id>urn:sha1:6a1c10bd85442f52f1d55d51005481cfa5cb40b5</id>
<content type='text'>
Currently, the output of `rustc --explain foo` displays the raw markdown in a
pager. This is acceptable, but using actual formatting makes it easier to
understand.

This patch consists of three major components:

1.  A markdown parser. This is an extremely simple non-backtracking recursive
    implementation that requires normalization of the final token stream
2.  A utility to write the token stream to an output buffer
3.  Configuration within rustc_driver_impl to invoke this combination for
    `--explain`. Like the current implementation, it first attempts to print to
    a pager with a fallback colorized terminal, and standard print as a last
    resort.

    If color is disabled, or if the output does not support it, or if printing
    with color fails, it will write the raw markdown (which matches current
    behavior).

    Pagers known to support color are: `less` (with `-r`), `bat` (aka `catbat`),
    and `delta`.

The markdown parser does not support the entire markdown specification, but
should support the following with reasonable accuracy:

-   Headings, including formatting
-   Comments
-   Code, inline and fenced block (no indented block)
-   Strong, emphasis, and strikethrough formatted text
-   Links, anchor, inline, and reference-style
-   Horizontal rules
-   Unordered and ordered list items, including formatting

This parser and writer should be reusable by other systems if ever needed.
</content>
</entry>
</feed>
