diff options
author | Ted Kremenek <kremenek@apple.com> | 2010-01-28 00:55:28 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2010-01-28 00:55:28 +0000 |
commit | c06ead62f0dafb545ce8abc133dbc299c94a3e3b (patch) | |
tree | f7f7544f54ad95b023a125364772db4b88881b6e /clang/lib/Analysis/PrintfFormatString.cpp | |
parent | abb44137281fb63bd6efb5c5c46a0513654dbbee (diff) | |
download | bcm5719-llvm-c06ead62f0dafb545ce8abc133dbc299c94a3e3b.tar.gz bcm5719-llvm-c06ead62f0dafb545ce8abc133dbc299c94a3e3b.zip |
Add '@' conversion specifier.
llvm-svn: 94713
Diffstat (limited to 'clang/lib/Analysis/PrintfFormatString.cpp')
-rw-r--r-- | clang/lib/Analysis/PrintfFormatString.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/clang/lib/Analysis/PrintfFormatString.cpp b/clang/lib/Analysis/PrintfFormatString.cpp index d7b9a21a3dc..9907dc9d42b 100644 --- a/clang/lib/Analysis/PrintfFormatString.cpp +++ b/clang/lib/Analysis/PrintfFormatString.cpp @@ -193,9 +193,8 @@ static FormatSpecifierResult ParseFormatSpecifier(printf::FormatStringHandler &H switch (*I) { default: H.HandleInvalidConversionSpecifier(I); - return true; - - // Handle the cases we know about. + return true; + // C99: 7.19.6.1 (section 8). case 'd': cs = ConversionSpecifier::dArg; break; case 'i': cs = ConversionSpecifier::iArg; break; case 'o': cs = ConversionSpecifier::oArg; break; @@ -214,7 +213,9 @@ static FormatSpecifierResult ParseFormatSpecifier(printf::FormatStringHandler &H case 's': cs = ConversionSpecifier::CStrArg; break; case 'p': cs = ConversionSpecifier::VoidPtrArg; break; case 'n': cs = ConversionSpecifier::OutIntPtrArg; break; - case '%': cs = ConversionSpecifier::PercentArg; break; + case '%': cs = ConversionSpecifier::PercentArg; break; + // Objective-C. + case '@': cs = ConversionSpecifier::ObjCObjArg; break; } FS.setConversionSpecifier(cs); return FormatSpecifierResult(Start, FS); |