summaryrefslogtreecommitdiffstats
path: root/test/Parser/MicrosoftExtensions.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/Parser/MicrosoftExtensions.cpp')
-rw-r--r--test/Parser/MicrosoftExtensions.cpp34
1 files changed, 34 insertions, 0 deletions
diff --git a/test/Parser/MicrosoftExtensions.cpp b/test/Parser/MicrosoftExtensions.cpp
index 3a72ea0..89394c3 100644
--- a/test/Parser/MicrosoftExtensions.cpp
+++ b/test/Parser/MicrosoftExtensions.cpp
@@ -165,6 +165,11 @@ __interface MicrosoftInterface {
virtual void foo2() = 0;
};
+void interface_test() {
+ MicrosoftInterface* a;
+ a->foo1();
+}
+
__int64 x7 = __int64(0);
@@ -210,6 +215,35 @@ __if_not_exists(IF_EXISTS::Type_not) {
int var244;
}
+int __if_exists_init_list() {
+
+ int array1[] = {
+ 0,
+ __if_exists(IF_EXISTS::Type) {2, }
+ 3
+ };
+
+ int array2[] = {
+ 0,
+ __if_exists(IF_EXISTS::Type_not) { this wont compile }
+ 3
+ };
+
+ int array3[] = {
+ 0,
+ __if_not_exists(IF_EXISTS::Type_not) {2, }
+ 3
+ };
+
+ int array4[] = {
+ 0,
+ __if_not_exists(IF_EXISTS::Type) { this wont compile }
+ 3
+ };
+
+}
+
+
class IF_EXISTS_CLASS_TEST {
__if_exists(IF_EXISTS::Type) {
// __if_exists, __if_not_exists can nest
OpenPOWER on IntegriCloud