[PATCH] D51381: [clang-tidy] fix check_clang_tidy to forbid mixing of CHECK-NOTES and CHECK-MESSAGES

Jonas Toth via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Aug 30 01:45:22 PDT 2018


This revision was automatically updated to reflect the committed changes.
Closed by commit rL341039: [clang-tidy] fix check_clang_tidy to forbid mixing of CHECK-NOTES and CHECKā€¦ (authored by JonasToth, committed by ).
Herald added a subscriber: llvm-commits.

Repository:
  rL LLVM

https://reviews.llvm.org/D51381

Files:
  clang-tools-extra/trunk/test/clang-tidy/check_clang_tidy.py


Index: clang-tools-extra/trunk/test/clang-tidy/check_clang_tidy.py
===================================================================
--- clang-tools-extra/trunk/test/clang-tidy/check_clang_tidy.py
+++ clang-tools-extra/trunk/test/clang-tidy/check_clang_tidy.py
@@ -98,6 +98,9 @@
     sys.exit('%s, %s or %s not found in the input' % (check_fixes_prefix,
              check_messages_prefix, check_notes_prefix) )
 
+  if has_check_notes and has_check_messages:
+    sys.exit('Please use either CHECK-NOTES or CHECK-MESSAGES but not both')
+
   # Remove the contents of the CHECK lines to avoid CHECKs matching on
   # themselves.  We need to keep the comments to preserve line numbers while
   # avoiding empty lines which could potentially trigger formatting-related


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D51381.163279.patch
Type: text/x-patch
Size: 770 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180830/c538ca10/attachment.bin>


More information about the cfe-commits mailing list