summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/ext/visibility/symbian1.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.dg/ext/visibility/symbian1.C')
-rw-r--r--gcc/testsuite/g++.dg/ext/visibility/symbian1.C22
1 files changed, 22 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/ext/visibility/symbian1.C b/gcc/testsuite/g++.dg/ext/visibility/symbian1.C
new file mode 100644
index 000000000..864ab2bb9
--- /dev/null
+++ b/gcc/testsuite/g++.dg/ext/visibility/symbian1.C
@@ -0,0 +1,22 @@
+// { dg-do compile { target arm*-*-symbianelf* } }
+// Class data should not be exported.
+// { dg-final { scan-hidden "_ZTV2K3" } }
+// But the constructor and destructor should be exported.
+// { dg-final { scan-not-hidden "_ZN2K3C2Ev" } }
+// { dg-final { scan-not-hidden "_ZN2K3D0Ev" } }
+
+class __declspec(notshared) K3 {
+public:
+ __declspec(dllimport) K3();
+ __declspec(dllimport) virtual ~K3();
+ virtual int m1();
+};
+
+__declspec(dllexport)
+ K3::K3(){}
+
+__declspec(dllexport)
+ K3::~K3(){}
+
+int K3::m1() { return 1; }
+