diff options
| author | Richard Smith <richard-llvm@metafoo.co.uk> | 2019-07-29 20:00:46 +0000 |
|---|---|---|
| committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2019-07-29 20:00:46 +0000 |
| commit | e8b659fc1ff02354438b1be0ff7016a12ec47603 (patch) | |
| tree | 1a358437bff62ff17a5c8967da4d3144c9964078 /clang/lib | |
| parent | a625da716c8300d2ff9ec2313e7b38892bcfcfcb (diff) | |
| download | bcm5719-llvm-e8b659fc1ff02354438b1be0ff7016a12ec47603.tar.gz bcm5719-llvm-e8b659fc1ff02354438b1be0ff7016a12ec47603.zip | |
Give the 'signed/unsigned wchar_t' extension a warning flag, and follow
GCC 9 in promoting it to an error by default.
llvm-svn: 367255
Diffstat (limited to 'clang/lib')
| -rw-r--r-- | clang/lib/Sema/SemaType.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/Sema/SemaType.cpp b/clang/lib/Sema/SemaType.cpp index 62ff33ae7e2..00e2a0cdc3a 100644 --- a/clang/lib/Sema/SemaType.cpp +++ b/clang/lib/Sema/SemaType.cpp @@ -1290,14 +1290,14 @@ static QualType ConvertDeclSpecToType(TypeProcessingState &state) { if (DS.getTypeSpecSign() == DeclSpec::TSS_unspecified) Result = Context.WCharTy; else if (DS.getTypeSpecSign() == DeclSpec::TSS_signed) { - S.Diag(DS.getTypeSpecSignLoc(), diag::ext_invalid_sign_spec) + S.Diag(DS.getTypeSpecSignLoc(), diag::ext_wchar_t_sign_spec) << DS.getSpecifierName(DS.getTypeSpecType(), Context.getPrintingPolicy()); Result = Context.getSignedWCharType(); } else { assert(DS.getTypeSpecSign() == DeclSpec::TSS_unsigned && "Unknown TSS value"); - S.Diag(DS.getTypeSpecSignLoc(), diag::ext_invalid_sign_spec) + S.Diag(DS.getTypeSpecSignLoc(), diag::ext_wchar_t_sign_spec) << DS.getSpecifierName(DS.getTypeSpecType(), Context.getPrintingPolicy()); Result = Context.getUnsignedWCharType(); |

