summaryrefslogtreecommitdiffstats
path: root/clang/test/Analysis/inline.cpp
diff options
context:
space:
mode:
authorJordan Rose <jordan_rose@apple.com>2013-04-22 21:36:44 +0000
committerJordan Rose <jordan_rose@apple.com>2013-04-22 21:36:44 +0000
commit3437669ca94236918c654f042e33dfa0c32cbd0f (patch)
tree51b4ffeacba98e3e1e790fcec55ec5fa7998d81b /clang/test/Analysis/inline.cpp
parent7f3aa1081cf0bafb0d420932d4d60b122df405f7 (diff)
downloadbcm5719-llvm-3437669ca94236918c654f042e33dfa0c32cbd0f.tar.gz
bcm5719-llvm-3437669ca94236918c654f042e33dfa0c32cbd0f.zip
[analyzer] Type information from C++ new expressions is perfect.
This improves our handling of dynamic_cast and devirtualization for objects allocated by 'new'. llvm-svn: 180051
Diffstat (limited to 'clang/test/Analysis/inline.cpp')
-rw-r--r--clang/test/Analysis/inline.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/clang/test/Analysis/inline.cpp b/clang/test/Analysis/inline.cpp
index a16fa00d12b..62bce284721 100644
--- a/clang/test/Analysis/inline.cpp
+++ b/clang/test/Analysis/inline.cpp
@@ -351,9 +351,7 @@ namespace VirtualWithSisterCasts {
void testCastViaNew(B *b) {
Grandchild *g = new (b) Grandchild();
- // FIXME: We actually now have perfect type info because of 'new'.
- // This should be TRUE.
- clang_analyzer_eval(g->foo() == 42); // expected-warning{{UNKNOWN}}
+ clang_analyzer_eval(g->foo() == 42); // expected-warning{{TRUE}}
g->x = 42;
clang_analyzer_eval(g->x == 42); // expected-warning{{TRUE}}
OpenPOWER on IntegriCloud