diff options
| author | Jordan Rose <jordan_rose@apple.com> | 2013-07-17 17:16:33 +0000 |
|---|---|---|
| committer | Jordan Rose <jordan_rose@apple.com> | 2013-07-17 17:16:33 +0000 |
| commit | 05b2f98d891b56f85186aa6da61ad417b8153730 (patch) | |
| tree | 559e3b2eeda8033b2aa0d9a6e67beaed7c57725d /clang/lib/StaticAnalyzer/Core/ExprEngine.cpp | |
| parent | fb624ce8857024488286a1bb7556a59299565ca2 (diff) | |
| download | bcm5719-llvm-05b2f98d891b56f85186aa6da61ad417b8153730.tar.gz bcm5719-llvm-05b2f98d891b56f85186aa6da61ad417b8153730.zip | |
[analyzer] Treat std::initializer_list as opaque rather than aborting.
Previously, the use of a std::initializer_list (actually, a
CXXStdInitializerListExpr) would cause the analyzer to give up on the rest
of the path. Now, it just uses an opaque symbolic value for the
initializer_list and continues on.
At some point in the future we can add proper support for initializer_list,
with access to the elements in the InitListExpr.
<rdar://problem/14340207>
llvm-svn: 186519
Diffstat (limited to 'clang/lib/StaticAnalyzer/Core/ExprEngine.cpp')
| -rw-r--r-- | clang/lib/StaticAnalyzer/Core/ExprEngine.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp b/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp index 39ca429e19d..ff8a9e86613 100644 --- a/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp +++ b/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp @@ -615,7 +615,6 @@ void ExprEngine::Visit(const Stmt *S, ExplodedNode *Pred, case Stmt::CXXDefaultInitExprClass: case Stmt::CXXDependentScopeMemberExprClass: case Stmt::CXXPseudoDestructorExprClass: - case Stmt::CXXStdInitializerListExprClass: case Stmt::CXXTryStmtClass: case Stmt::CXXTypeidExprClass: case Stmt::CXXUuidofExprClass: @@ -776,10 +775,10 @@ void ExprEngine::Visit(const Stmt *S, ExplodedNode *Pred, break; } + // Cases we evaluate as opaque expressions, conjuring a symbol. + case Stmt::CXXStdInitializerListExprClass: case Expr::ObjCArrayLiteralClass: case Expr::ObjCDictionaryLiteralClass: - // FIXME: explicitly model with a region and the actual contents - // of the container. For now, conjure a symbol. case Expr::ObjCBoxedExprClass: { Bldr.takeNodes(Pred); |

