diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2013-12-09 14:51:17 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2013-12-09 14:51:17 +0000 |
commit | d6c0a824b6fdaffd12cf64ee136973278ae20c08 (patch) | |
tree | afb8ed3c1c78bad75fc1b51e6148d15a069711f6 /test/CodeGenCXX/virtual-destructor-calls.cpp | |
parent | 9c009bca6da945074f0d5d496bd87da13e20eaea (diff) |
Output destructors and constructors in a more natural order.
With this patch we output the in the order
C2
C1
D2
D1
D0
Which means that a destructor or constructor that call another is output after
the callee. This is a bit easier to read IHMO and a tiny bit more efficient
as we don't put a decl in DeferredDeclsToEmit.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196784 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGenCXX/virtual-destructor-calls.cpp')
-rw-r--r-- | test/CodeGenCXX/virtual-destructor-calls.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/test/CodeGenCXX/virtual-destructor-calls.cpp b/test/CodeGenCXX/virtual-destructor-calls.cpp index ae3704f369..3e7fa8293a 100644 --- a/test/CodeGenCXX/virtual-destructor-calls.cpp +++ b/test/CodeGenCXX/virtual-destructor-calls.cpp @@ -20,16 +20,16 @@ struct B : A { // CHECK: @_ZN1CD1Ev = alias {{.*}} @_ZN1CD2Ev // CHECK: @_ZN1CD2Ev = alias bitcast {{.*}} @_ZN1BD2Ev -// Deleting dtor: defers to the complete dtor. -// CHECK-LABEL: define void @_ZN1BD0Ev(%struct.B* %this) unnamed_addr -// CHECK: call void @_ZN1BD1Ev -// CHECK: call void @_ZdlPv - // Base dtor: actually calls A's base dtor. // CHECK-LABEL: define void @_ZN1BD2Ev(%struct.B* %this) unnamed_addr // CHECK: call void @_ZN6MemberD1Ev // CHECK: call void @_ZN1AD2Ev +// Deleting dtor: defers to the complete dtor. +// CHECK-LABEL: define void @_ZN1BD0Ev(%struct.B* %this) unnamed_addr +// CHECK: call void @_ZN1BD1Ev +// CHECK: call void @_ZdlPv + B::~B() { } struct C : B { |