diff options
author | Nico Weber <nicolasweber@gmx.de> | 2012-01-31 01:43:25 +0000 |
---|---|---|
committer | Nico Weber <nicolasweber@gmx.de> | 2012-01-31 01:43:25 +0000 |
commit | 339b9072e26a2a0fe796dc69c4d28d964d0ec86d (patch) | |
tree | 97cc47547aee64f659a6ea3197952a199fe53c7b /lib/Sema/SemaChecking.cpp | |
parent | c9674be201cf17d8e1c1c9f8b2c8c3a4474a43db (diff) |
Let %S, %ls, %C match 16bit types in NSStrings.
As discussed at http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20120130/052200.html
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149325 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaChecking.cpp')
-rw-r--r-- | lib/Sema/SemaChecking.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Sema/SemaChecking.cpp b/lib/Sema/SemaChecking.cpp index 7a852aefad..092bf5b597 100644 --- a/lib/Sema/SemaChecking.cpp +++ b/lib/Sema/SemaChecking.cpp @@ -2162,7 +2162,8 @@ CheckPrintfHandler::HandlePrintfSpecifier(const analyze_printf::PrintfSpecifier // Now type check the data expression that matches the // format specifier. const Expr *Ex = getDataArg(argIndex); - const analyze_printf::ArgTypeResult &ATR = FS.getArgType(S.Context); + const analyze_printf::ArgTypeResult &ATR = FS.getArgType(S.Context, + IsObjCLiteral); if (ATR.isValid() && !ATR.matchesType(S.Context, Ex->getType())) { // Check if we didn't match because of an implicit cast from a 'char' // or 'short' to an 'int'. This is done because printf is a varargs |