From 27c39af73c0d7d0b97e57b3a905040d4cefc9708 Mon Sep 17 00:00:00 2001 From: rdivacky Date: Wed, 10 Mar 2010 17:45:58 +0000 Subject: Update clang to r98164. --- test/SemaCXX/dynamic-cast.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'test/SemaCXX/dynamic-cast.cpp') diff --git a/test/SemaCXX/dynamic-cast.cpp b/test/SemaCXX/dynamic-cast.cpp index 53d0b9d..b73e8c5 100644 --- a/test/SemaCXX/dynamic-cast.cpp +++ b/test/SemaCXX/dynamic-cast.cpp @@ -8,7 +8,7 @@ struct D : private A {}; struct E : A {}; struct F : B, E {}; -struct Incomplete; // expected-note 2 {{forward declaration of 'struct Incomplete'}} +struct Incomplete; // expected-note 2 {{forward declaration of 'Incomplete'}} struct Poly { @@ -22,7 +22,7 @@ struct PolyDerived : Poly void basic_bad() { // ptr -> nonptr - (void)dynamic_cast((A*)0); // expected-error {{'struct A' is not a reference or pointer}} + (void)dynamic_cast((A*)0); // expected-error {{'A' is not a reference or pointer}} // nonptr -> ptr (void)dynamic_cast(0); // expected-error {{'int' is not a pointer}} // ptr -> noncls @@ -34,9 +34,9 @@ void basic_bad() // noncls -> ref (void)dynamic_cast(*((int*)0)); // expected-error {{'int' is not a class}} // ptr -> incomplete - (void)dynamic_cast((A*)0); // expected-error {{'struct Incomplete' is an incomplete type}} + (void)dynamic_cast((A*)0); // expected-error {{'Incomplete' is an incomplete type}} // incomplete -> ptr - (void)dynamic_cast((Incomplete*)0); // expected-error {{'struct Incomplete' is an incomplete type}} + (void)dynamic_cast((Incomplete*)0); // expected-error {{'Incomplete' is an incomplete type}} } void same() @@ -57,8 +57,8 @@ void up() //(void)dynamic_cast(*((D*)0)); // Ambiguous - (void)dynamic_cast((F*)0); // expected-error {{ambiguous conversion from derived class 'struct F' to base class 'struct A':\n struct F -> struct B -> struct A\n struct F -> struct E -> struct A}} - (void)dynamic_cast(*((F*)0)); // expected-error {{ambiguous conversion from derived class 'struct F' to base class 'struct A':\n struct F -> struct B -> struct A\n struct F -> struct E -> struct A}} + (void)dynamic_cast((F*)0); // expected-error {{ambiguous conversion from derived class 'F' to base class 'A':\n struct F -> struct B -> struct A\n struct F -> struct E -> struct A}} + (void)dynamic_cast(*((F*)0)); // expected-error {{ambiguous conversion from derived class 'F' to base class 'A':\n struct F -> struct B -> struct A\n struct F -> struct E -> struct A}} } void poly() @@ -69,6 +69,6 @@ void poly() (void)dynamic_cast(*((PolyDerived*)0)); // Not polymorphic source - (void)dynamic_cast((A*)0); // expected-error {{'struct A' is not polymorphic}} - (void)dynamic_cast(*((A*)0)); // expected-error {{'struct A' is not polymorphic}} + (void)dynamic_cast((A*)0); // expected-error {{'A' is not polymorphic}} + (void)dynamic_cast(*((A*)0)); // expected-error {{'A' is not polymorphic}} } -- cgit v1.1