aboutsummaryrefslogtreecommitdiff
path: root/test/SemaCXX/ms-interface.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2012-09-25 07:32:49 +0000
committerJohn McCall <rjmccall@apple.com>2012-09-25 07:32:49 +0000
commitea30e2f8667668173cf7433c3c80cf603bd922a4 (patch)
tree55eff9d2c54cd8fc5c3128535412de722c489fb5 /test/SemaCXX/ms-interface.cpp
parente402e72273cde2a64fa6097c1fe93f500038675d (diff)
Add the Microsoft __is_interface_class type trait.
Patch by Andy Gibbs! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@164591 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaCXX/ms-interface.cpp')
-rw-r--r--test/SemaCXX/ms-interface.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/SemaCXX/ms-interface.cpp b/test/SemaCXX/ms-interface.cpp
index 62ae25482f..3625f7027a 100644
--- a/test/SemaCXX/ms-interface.cpp
+++ b/test/SemaCXX/ms-interface.cpp
@@ -59,6 +59,10 @@ struct S { };
class C { };
__interface I { };
+static_assert(!__is_interface_class(S), "oops");
+static_assert(!__is_interface_class(C), "oops");
+static_assert(__is_interface_class(I), "oops");
+
// expected-error@55 {{interface type cannot inherit from 'struct S'}}
// expected-note@+1 {{in instantiation of template class 'I6<S>' requested here}}
struct S1 : I6<S> {