1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97
|
#include "swift-types.h"
using namespace a;
int testFunc() {
swiftFunc(); // Break here for func
return 0;
}
int testMethodClass() {
auto swiftClass = SwiftClass::init();
swiftClass.swiftMethod(); // Break here for method - class
return 0;
}
int testConstructorClass() {
auto swiftClass = SwiftClass::init(); // Break here for constructor - class
return 0;
}
int testStaticMethodClass() {
SwiftClass::swiftStaticMethod(); // Break here for static method - class
return 0;
}
int testGetterClass() {
auto swiftClass = SwiftClass::init();
swiftClass.getSwiftProperty(); // Break here for getter - class
return 0;
}
int testSetterClass() {
auto swiftClass = SwiftClass::init();
auto str = getString();
swiftClass.setSwiftProperty(str); // Break here for setter - class
return 0;
}
int testOverridenMethodClass() {
auto swiftClass = SwiftSubclass::init();
swiftClass.overrideableMethod(); // Break here for overridden - class
return 0;
}
void testClass() {
testMethodClass();
testConstructorClass();
testStaticMethodClass();
testGetterClass();
testSetterClass();
testOverridenMethodClass();
}
int testMethodStruct() {
auto swiftStruct = SwiftStruct::init();
swiftStruct.swiftMethod(); // Break here for method - struct
return 0;
}
int testConstructorStruct() {
auto swiftStruct = SwiftStruct::init(); // Break here for constructor - struct
return 0;
}
int testStaticMethodStruct() {
SwiftStruct::swiftStaticMethod(); // Break here for static method - struct
return 0;
}
int testGetterStruct() {
auto swiftStruct = SwiftStruct::init();
swiftStruct.getSwiftProperty(); // Break here for getter - struct
return 0;
}
int testSetterStruct() {
auto swiftStruct = SwiftStruct::init();
auto str = getString();
swiftStruct.setSwiftProperty(str); // Break here for setter - struct
return 0;
}
void testStruct() {
testMethodStruct();
testConstructorStruct();
testStaticMethodStruct();
testGetterStruct();
testSetterStruct();
}
int main() {
testFunc();
testClass();
testStruct();
return 0;
}
|