diff options
author | Ted Kremenek <kremenek@apple.com> | 2010-02-01 23:23:50 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2010-02-01 23:23:50 +0000 |
commit | f911eba72e6d7275e5cfdb79ab23fb2aa9cc01d0 (patch) | |
tree | 5fe5f7d8612cbe04d56d6a85e1d1974f12a5e524 /lib/Analysis/PrintfFormatString.cpp | |
parent | ce78c9743aa8272b880a2874393fceff766c3fa3 (diff) |
Add format string type checking support for 'long double'.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@95026 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/PrintfFormatString.cpp')
-rw-r--r-- | lib/Analysis/PrintfFormatString.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/Analysis/PrintfFormatString.cpp b/lib/Analysis/PrintfFormatString.cpp index d2bcbb04f9..35c620aded 100644 --- a/lib/Analysis/PrintfFormatString.cpp +++ b/lib/Analysis/PrintfFormatString.cpp @@ -311,8 +311,11 @@ ArgTypeResult FormatSpecifier::getArgType(ASTContext &Ctx) const { return ArgTypeResult(); } - if (CS.isDoubleArg()) + if (CS.isDoubleArg()) { + if (LM == AsLongDouble) + return Ctx.LongDoubleTy; return Ctx.DoubleTy; + } // FIXME: Handle other cases. return ArgTypeResult(); |