llvm-capstone/clang/lib
Hubert Tong c6ffe4d76f [clang] Fix message text for -Wpointer-sign to account for plain char
The `-Wpointer-sign` warning text is inappropriate for describing the
incompatible pointer conversion between plain `char` and explicitly
`signed`/`unsigned` `char` (whichever plain `char` has the same range
as) and vice versa.

Specifically, in part, it reads "converts between pointers to integer
types with different sign". This patch changes that portion to read
instead as "converts between pointers to integer types where one is of
the unique plain 'char' type and the other is not" when one of the types
is plain `char`.

C17 subclause 6.5.16.1 indicates that the conversions resulting in
`-Wpointer-sign` warnings in assignment-like contexts are constraint
violations. This means that strict conformance requires a diagnostic for
the case where the message text is wrong before this patch. The lack of
an even more specialized warning group is consistent with GCC.

Reviewed By: aaron.ballman

Differential Revision: https://reviews.llvm.org/D93999
2021-01-11 18:41:14 -05:00
..
Analysis Revert "Revert "Revert "Revert "Revert "[analyzer] NFC: Move path diagnostic consumer implementations to libAnalysis.""""" 2021-01-08 14:17:18 +01:00
APINotes APINotes: annotate dump methods (NFC) 2021-01-08 20:49:28 +00:00
ARCMigrate ARCMigrate: Migrate ObjCMT.cpp over to FileEntryRef 2020-12-09 14:16:05 -08:00
AST [clangd] Fix type printing in the presence of qualifiers 2021-01-08 17:00:39 +01:00
ASTMatchers [ASTMatchers] Fix child traversal over range-for loops 2021-01-05 21:29:37 +00:00
Basic [AArch64] Add +flagm archictecture option, allowing the v8.4a flag modification extension. 2021-01-08 13:21:12 +00:00
CodeGen CGDebugInfo: Delete unused parameters 2021-01-11 13:39:03 -08:00
CrossTU Revert "Revert "Revert "Revert "Revert "[analyzer] NFC: Move path diagnostic consumer implementations to libAnalysis.""""" 2021-01-08 14:17:18 +01:00
DirectoryWatcher Revert "ADT: Migrate users of AlignedCharArrayUnion to std::aligned_union_t, NFC" 2020-12-14 17:04:06 -08:00
Driver clang: Always pass PowerPC endian information to GNU as 2021-01-11 14:50:28 -08:00
Edit [clang] Use SourceLocation as key in hash maps, NFCI 2020-10-20 16:24:09 +01:00
Format [clang-format] Find main include after block ended with #pragma hdrstop 2021-01-11 09:49:34 +01:00
Frontend Reapply "[clang][cli] Port DiagnosticOpts to new option parsing system" 2021-01-11 10:05:53 +01:00
FrontendTool
Headers [PowerPC] Add variants of 64-bit vector types for vec_sel. 2021-01-11 03:52:16 +00:00
Index Revert "[c++20] P1907R1: Support for generalized non-type template arguments of scalar type." 2020-12-22 10:18:08 -08:00
IndexSerialization [index-while-building] Fix build with -DBUILD_SHARED_LIBS=True 2020-08-20 15:12:56 +01:00
Lex Revert "Lex: Migrate HeaderSearch::LoadedModuleMaps to FileEntryRef" 2020-12-14 22:05:08 -05:00
Parse [SVE] Add support to vectorize_width loop pragma for scalable vectors 2021-01-08 11:37:27 +00:00
Rewrite SourceManager: Clarify that FileInfo always has a ContentCache, NFC 2020-10-23 12:38:53 -04:00
Sema [clang] Fix message text for -Wpointer-sign to account for plain char 2021-01-11 18:41:14 -05:00
Serialization [NFC] Renaming PackStack to AlignPackStack 2021-01-08 09:15:11 -05:00
StaticAnalyzer Revert "Revert "Revert "Revert "Revert "[analyzer] NFC: Move path diagnostic consumer implementations to libAnalysis.""""" 2021-01-08 14:17:18 +01:00
Testing
Tooling [CompilationDatabase] Pass Twine by const reference instead of by value. NFCI. 2021-01-07 12:53:28 +00:00
CMakeLists.txt APINotes: add APINotesYAMLCompiler 2020-11-05 18:55:13 +00:00