rust/compiler/rustc_errors/src
Nicholas Nethercote 883bdb7fda Remove HandlerInner::emit.
This is weird: `HandlerInner::emit` calls
`HandlerInner::emit_diagnostic`, but only after doing a
`treat-err-as-bug` check. Which is fine, *except* that there are
multiple others paths for an `Error` or `Fatal` diagnostic to be passed
to `HandlerInner::emit_diagnostic` without going through
`HandlerInner::emit`, e.g. `Handler::span_err` call
`Handler::emit_diag_at_span`, which calls `emit_diagnostic`.
So that suggests that the coverage for `treat-err-as-bug` is incomplete.

This commit removes `HandlerInner::emit` and moves the
`treat-err-as-bug` check to `HandlerInner::emit_diagnostic`, so it
cannot by bypassed.
2023-12-04 18:57:42 +11:00
..
json Use a builder instead of boolean/option arguments 2023-07-25 13:51:15 +00:00
markdown Fix some typos 2023-11-14 23:06:50 +08:00
annotate_snippet_emitter_writer.rs Fix clippy::needless_borrow in the compiler 2023-11-21 20:13:40 +01:00
diagnostic_builder.rs Use DiagnosticBuilder::new more. 2023-12-04 18:57:42 +11:00
diagnostic_impls.rs Prevent promotion of const fn calls in inline consts 2023-09-21 09:00:22 +00:00
diagnostic.rs Remove some unused code, and downgrade some pubs. 2023-12-04 18:57:42 +11:00
emitter.rs Fix clippy::needless_borrow in the compiler 2023-11-21 20:13:40 +01:00
error.rs Make translate_message return result and add tests 2023-01-08 23:35:43 +01:00
json.rs Update some more cases of "type" -> "$message_type" 2023-11-20 16:02:59 -08:00
lib.rs Remove HandlerInner::emit. 2023-12-04 18:57:42 +11:00
lock.rs bump windows crate 0.46 -> 0.48 in workspace 2023-05-09 18:20:13 +03:00
registry.rs refactor: statically guarantee that current error codes are documented 2023-02-26 20:12:36 +13:00
snippet.rs Create AnnotationColumn struct to fix hard tab column numbers in errors 2023-03-28 09:18:55 -04:00
styled_buffer.rs Replace some _ == _ || _ == _s with matches!(_, _ | _)s 2023-01-30 12:26:26 +00:00
tests.rs Format all the let chains in compiler 2023-10-13 08:59:36 +00:00
translation.rs Restore behavior when primary bundle is missing 2023-02-23 01:14:10 +01:00