mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 21:41:27 +01:00
Add a way for diagnostics to sort on more than last_byte_offset. (#6687)
The intent is that `last_byte_offset` is still the main sorting key. Diagnostics issued normally (e.g. in an expression) will keep sorting the same, and come before the new diagnostic sort. Diagnostics issued at the end of a scope (e.g. `unused`) can request sorting by their start location, and would become interleaved through that. Choosing "on scope" because I think that's the main way we'll use this functionality (on scope changes); can always rename later if usage expands. Assisted-by: Google Antigravity with Gemini 3 Flash
This commit is contained in:
@@ -22,6 +22,7 @@ constexpr Kind Kinds[] = {
|
||||
constexpr Kind UntestedKinds[] = {
|
||||
// These exist only for unit tests.
|
||||
Kind::TestDiagnostic,
|
||||
Kind::TestDiagnosticOnScope,
|
||||
Kind::TestDiagnosticNote,
|
||||
|
||||
// Diagnosing erroneous install conditions, but test environments are
|
||||
|
||||
Reference in New Issue
Block a user