Add a note: prefix to all notes. (#4330)

Omit the `note: ` prefix and the snippet from the "in import" note that
precedes a diagnostic.

This makes our diagnostic output more closely match that of Clang and
GCC.
This commit is contained in:
Richard Smith
2024-09-23 23:59:25 +00:00
committed by GitHub
parent c107aaad13
commit 8d45530c5f
163 changed files with 725 additions and 940 deletions
+1 -1
View File
@@ -11,7 +11,7 @@
// CHECK:STDERR: fail_deref_type.carbon:[[@LINE+7]]:8: error: cannot dereference operand of non-pointer type `type`
// CHECK:STDERR: var p: *i32;
// CHECK:STDERR: ^
// CHECK:STDERR: fail_deref_type.carbon:[[@LINE+4]]:8: to form a pointer type, write the `*` after the pointee type
// CHECK:STDERR: fail_deref_type.carbon:[[@LINE+4]]:8: note: to form a pointer type, write the `*` after the pointee type
// CHECK:STDERR: var p: *i32;
// CHECK:STDERR: ^
// CHECK:STDERR:
+1 -1
View File
@@ -12,7 +12,7 @@ fn ConstMismatch(p: const {}*) -> const ({}*) {
// CHECK:STDERR: fail_type_mismatch.carbon:[[@LINE+6]]:3: error: cannot implicitly convert from `const {}*` to `const ({}*)`
// CHECK:STDERR: return p;
// CHECK:STDERR: ^~~~~~~~~
// CHECK:STDERR: fail_type_mismatch.carbon:[[@LINE+3]]:3: type `const {}*` does not implement interface `ImplicitAs`
// CHECK:STDERR: fail_type_mismatch.carbon:[[@LINE+3]]:3: note: type `const {}*` does not implement interface `ImplicitAs`
// CHECK:STDERR: return p;
// CHECK:STDERR: ^~~~~~~~~
return p;