Skip to content

Commit 6dd78f5

Browse files
TheSamsamark-i-m
authored andcommitted
Correct statement that wrongly claims the json emitter still lives in libsyntax crate
1 parent e695b62 commit 6dd78f5

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

src/diagnostics.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -357,14 +357,12 @@ string; this was introduced so that UI tests could both make use of
357357
the structured JSON and see the "human" output (well, _sans_ colors)
358358
without having to compile everything twice.
359359

360-
The JSON emitter currently lives in libsyntax/json.rs. (But arguably
361-
it should live in librustc_errors along with the "human" emitter? It's
362-
not obvious to the present author why it wasn't moved from libsyntax
363-
to librustc_errors at the same [time the "human" emitter was
364-
moved](https://github.com/rust-lang/rust/commit/6ae3502134).)
360+
The "human" readable and the json format emitter can be found under
361+
librustc_errors, both were moved from the libsyntax crate to the
362+
[librustc_errors crate](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_errors/index.html).
365363

366364
The JSON emitter defines [its own `Diagnostic`
367-
struct](https://github.com/rust-lang/rust/blob/b2c6b8c29f13f8d1f242da89e587960b95337819/src/libsyntax/json.rs#L85-L99)
365+
struct](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_errors/json/struct.Diagnostic.html)
368366
(and sub-structs) for the JSON serialization. Don't confuse this with
369367
[`errors::Diagnostic`](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_errors/struct.Diagnostic.html)!
370368

0 commit comments

Comments
 (0)