diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2020-07-31 21:22:58 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2020-07-31 21:22:58 +0000 |
commit | 5ffd83dbcc34f10e07f6d3e968ae6365869615f4 (patch) | |
tree | 0e9f5cf729dde39f949698fddef45a34e2bc7f44 /contrib/llvm-project/clang/lib/AST/PrintfFormatString.cpp | |
parent | 1799696096df87b52968b8996d00c91e0a5de8d9 (diff) | |
parent | cfca06d7963fa0909f90483b42a6d7d194d01e08 (diff) |
Notes
Diffstat (limited to 'contrib/llvm-project/clang/lib/AST/PrintfFormatString.cpp')
-rw-r--r-- | contrib/llvm-project/clang/lib/AST/PrintfFormatString.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/contrib/llvm-project/clang/lib/AST/PrintfFormatString.cpp b/contrib/llvm-project/clang/lib/AST/PrintfFormatString.cpp index dabc39c57ef7..f3ac181214ac 100644 --- a/contrib/llvm-project/clang/lib/AST/PrintfFormatString.cpp +++ b/contrib/llvm-project/clang/lib/AST/PrintfFormatString.cpp @@ -11,10 +11,11 @@ // //===----------------------------------------------------------------------===// +#include "FormatStringParsing.h" #include "clang/AST/FormatString.h" #include "clang/AST/OSLog.h" -#include "FormatStringParsing.h" #include "clang/Basic/TargetInfo.h" +#include "llvm/Support/Regex.h" using clang::analyze_format_string::ArgType; using clang::analyze_format_string::FormatStringHandler; @@ -316,8 +317,8 @@ static PrintfSpecifierResult ParsePrintfSpecifier(FormatStringHandler &H, case 'g': k = ConversionSpecifier::gArg; break; case 'i': k = ConversionSpecifier::iArg; break; case 'n': - // Not handled, but reserved in OpenCL and FreeBSD kernel. - if (!LO.OpenCL && !isFreeBSDKPrintf) + // Not handled, but reserved in OpenCL. + if (!LO.OpenCL) k = ConversionSpecifier::nArg; break; case 'o': k = ConversionSpecifier::oArg; break; @@ -751,6 +752,7 @@ bool PrintfSpecifier::fixType(QualType QT, const LangOptions &LangOpt, case BuiltinType::UInt128: case BuiltinType::Int128: case BuiltinType::Half: + case BuiltinType::BFloat16: case BuiltinType::Float16: case BuiltinType::Float128: case BuiltinType::ShortAccum: |