diff options
author | dim <dim@FreeBSD.org> | 2013-12-22 00:07:40 +0000 |
---|---|---|
committer | dim <dim@FreeBSD.org> | 2013-12-22 00:07:40 +0000 |
commit | 952eddef9aff85b1e92626e89baaf7a360e2ac85 (patch) | |
tree | df8df0b0067b381eab470a3b8f28d14a552a6340 /test/Analysis/initializers-cfg-output.cpp | |
parent | ea266cad53e3d49771fa38103913d3ec7a166694 (diff) | |
download | FreeBSD-src-952eddef9aff85b1e92626e89baaf7a360e2ac85.zip FreeBSD-src-952eddef9aff85b1e92626e89baaf7a360e2ac85.tar.gz |
Vendor import of clang release_34 branch r197841 (effectively, 3.4 RC3):
https://llvm.org/svn/llvm-project/cfe/branches/release_34@197841
Diffstat (limited to 'test/Analysis/initializers-cfg-output.cpp')
-rw-r--r-- | test/Analysis/initializers-cfg-output.cpp | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/test/Analysis/initializers-cfg-output.cpp b/test/Analysis/initializers-cfg-output.cpp index b62d979..db3c0fb 100644 --- a/test/Analysis/initializers-cfg-output.cpp +++ b/test/Analysis/initializers-cfg-output.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=debug.DumpCFG %s 2>&1 | FileCheck %s +// RUN: %clang_cc1 -std=c++11 -analyze -analyzer-checker=debug.DumpCFG %s 2>&1 | FileCheck %s class A { public: @@ -43,6 +43,13 @@ TestControlFlow::TestControlFlow(bool b) int v; } +class TestDelegating { + int x, z; + public: + TestDelegating() : TestDelegating(2, 3) {} + TestDelegating(int x, int z) : x(x), z(z) {} +}; + // CHECK: [B2 (ENTRY)] // CHECK: Succs (1): B1 // CHECK: [B1] @@ -95,3 +102,14 @@ TestControlFlow::TestControlFlow(bool b) // CHECK: Succs (2): B2 B3 // CHECK: [B0 (EXIT)] // CHECK: Preds (1): B1 +// CHECK: [B2 (ENTRY)] +// CHECK: Succs (1): B1 +// CHECK: [B1] +// CHECK: 1: 2 +// CHECK: 2: 3 +// CHECK: 3: [B1.1], [B1.2] (CXXConstructExpr, class TestDelegating) +// CHECK: 4: TestDelegating([B1.3]) (Delegating initializer) +// CHECK: Preds (1): B2 +// CHECK: Succs (1): B0 +// CHECK: [B0 (EXIT)] +// CHECK: Preds (1): B1 |