Underline the complete declaration in diagnostics (#3508)

Builds upon @domisterwoozy 's excellent #3442 . Removes the need to
store the first node of a declaration in the declaration state stack.
This commit is contained in:
josh11b
2023-12-14 19:18:17 +00:00
committed by GitHub
parent 8282595bf8
commit 23c7d7dd99
33 changed files with 103 additions and 119 deletions
@@ -11,7 +11,7 @@ class Incomplete;
// CHECK:STDERR: ^~~~~~~~~~~~~~~
// CHECK:STDERR: fail_incomplete_element.carbon:[[@LINE-5]]:1: Class was forward declared here.
// CHECK:STDERR: class Incomplete;
// CHECK:STDERR: ^~~~~
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
var a: [Incomplete; 1];
// CHECK:STDERR: fail_incomplete_element.carbon:[[@LINE+3]]:1: ERROR: Cannot implicitly convert from `<error>*` to `Incomplete*`.