summaryrefslogtreecommitdiff
path: root/test cases/swift/11 mixed cpp/mylib.cpp
diff options
context:
space:
mode:
authorJussi Pakkanen <jussi.pakkanen@mailbox.org>2025-08-01 15:33:41 +0300
committerJussi Pakkanen <jussi.pakkanen@mailbox.org>2025-08-01 16:52:03 +0300
commitbf9ff6e5eee7a5b7bfb2b50b0dc5bf948e87eaae (patch)
treed360be6801ff7b6315c724907c490979f8c7819e /test cases/swift/11 mixed cpp/mylib.cpp
parent550cf5ebcc395dfa78bfc31ee2abc1550a9ed349 (diff)
downloadmeson-bf9ff6e5eee7a5b7bfb2b50b0dc5bf948e87eaae.tar.gz
Condense test directory names for 1.9.
Diffstat (limited to 'test cases/swift/11 mixed cpp/mylib.cpp')
-rw-r--r--test cases/swift/11 mixed cpp/mylib.cpp22
1 files changed, 22 insertions, 0 deletions
diff --git a/test cases/swift/11 mixed cpp/mylib.cpp b/test cases/swift/11 mixed cpp/mylib.cpp
new file mode 100644
index 000000000..0c616814e
--- /dev/null
+++ b/test cases/swift/11 mixed cpp/mylib.cpp
@@ -0,0 +1,22 @@
+#include "mylib.h"
+#include <iostream>
+
+Test::Test() {
+ std::cout << "Test initialized" << std::endl;
+}
+
+Test::Test(int param) {
+ std::cout << "Test initialized with param " << param << std::endl;
+}
+
+void Test::testCallFromClass() {
+ std::cout << "Calling C++ class function from Swift is working" << std::endl;
+}
+
+void testCallFromSwift() {
+ std::cout << "Calling this C++ function from Swift is working" << std::endl;
+}
+
+void testCallWithParam(const std::string &param) {
+ std::cout << param << std::endl;
+}