Reword diagnostics for style; NFC
authorAaron Ballman <aaron@aaronballman.com>
Mon, 10 Oct 2022 19:53:48 +0000 (15:53 -0400)
committerAaron Ballman <aaron@aaronballman.com>
Mon, 10 Oct 2022 19:53:48 +0000 (15:53 -0400)
This removes the capital letter at the start of a few diagnostics and
reformats the nearby diagnostics to match the local style.

clang/include/clang/Basic/DiagnosticCommonKinds.td
clang/test/Driver/stack-clash-protection-02.c
clang/test/Driver/stack-clash-protection.c
clang/test/Parser/slh-asm-goto.cpp

index e0408e9..38cc882 100644 (file)
@@ -273,23 +273,22 @@ def err_constexpr_invalid_template_arg : Error<
 
 // Sema && Frontend
 let CategoryName = "Inline Assembly Issue" in {
-  def err_asm_invalid_type_in_input : Error<
-    "invalid type %0 in asm input for constraint '%1'">;
+def err_asm_invalid_type_in_input : Error<
+  "invalid type %0 in asm input for constraint '%1'">;
 
-  def err_asm_invalid_type : Error<
-    "invalid type %0 in asm %select{input|output}1">;
+def err_asm_invalid_type : Error<
+  "invalid type %0 in asm %select{input|output}1">;
 
-  def err_ms_asm_bitfield_unsupported : Error<
-    "an inline asm block cannot have an operand which is a bit-field">;
+def err_ms_asm_bitfield_unsupported : Error<
+  "an inline asm block cannot have an operand which is a bit-field">;
 
-  def warn_stack_clash_protection_inline_asm : Warning<
-    "Unable to protect inline asm that clobbers stack pointer against stack clash">,
-    InGroup<DiagGroup<"stack-protector">>;
+def warn_stack_clash_protection_inline_asm : Warning<
+  "unable to protect inline asm that clobbers stack pointer against stack "
+  "clash">, InGroup<DiagGroup<"stack-protector">>;
 
-  def warn_slh_does_not_support_asm_goto
-      : Warning<"Speculative load hardening does not protect functions with "
-                "asm goto">,
-        InGroup<DiagGroup<"slh-asm-goto">>;
+def warn_slh_does_not_support_asm_goto : Warning<
+  "speculative load hardening does not protect functions with asm goto">,
+  InGroup<DiagGroup<"slh-asm-goto">>;
 }
 
 // Sema && Serialization
index 25ff3b5..eb236d0 100644 (file)
@@ -1,7 +1,7 @@
 // RUN: %clang -target s390x-linux-gnu -fstack-clash-protection -### %s 2>&1 | FileCheck %s -check-prefix=SystemZ
 // SystemZ: "-fstack-clash-protection"
 // RUN: %clang -target s390x-linux-gnu -fstack-clash-protection -S -emit-llvm -o %t.ll %s 2>&1 | FileCheck %s -check-prefix=SystemZ-warn
-// SystemZ-warn: warning: Unable to protect inline asm that clobbers stack pointer against stack clash
+// SystemZ-warn: warning: unable to protect inline asm that clobbers stack pointer against stack clash
 
 int foo(int c) {
   int r;
index 048668f..222452f 100644 (file)
@@ -13,7 +13,7 @@
 // SCP-armv7: argument unused during compilation: '-fstack-clash-protection'
 
 // RUN: %clang -target x86_64-unknown-linux -fstack-clash-protection -S -emit-llvm -o %t.ll %s 2>&1 | FileCheck %s -check-prefix=SCP-warn
-// SCP-warn: warning: Unable to protect inline asm that clobbers stack pointer against stack clash
+// SCP-warn: warning: unable to protect inline asm that clobbers stack pointer against stack clash
 
 // RUN: %clang -target x86_64-pc-unknown-linux -fstack-clash-protection -S -emit-llvm -o- %s | FileCheck %s -check-prefix=SCP-ll-linux64
 // SCP-ll-linux64: attributes {{.*}} "probe-stack"="inline-asm"
index 7ae3cbd..77bcd4f 100644 (file)
@@ -1,5 +1,5 @@
 // RUN: %clang_cc1 -mspeculative-load-hardening -fsyntax-only -verify %s
 
 void f() {
-  __asm goto("movl %ecx, %edx"); // expected-warning {{Speculative load hardening does not protect functions with asm goto}}
+  __asm goto("movl %ecx, %edx"); // expected-warning {{speculative load hardening does not protect functions with asm goto}}
 }