mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[SwiftToCxx] Creating new test case and fixing namespace
This commit is contained in:
@@ -21,19 +21,22 @@ int main() {
|
||||
|
||||
try {
|
||||
Functions::emptyThrowFunction();
|
||||
} catch (swift::_impl::swift::Error& e) {
|
||||
} catch (swift::Error& e) {
|
||||
printf("Exception\n");
|
||||
}
|
||||
try {
|
||||
Functions::throwFunction();
|
||||
} catch (swift::_impl::swift::Error& e) {
|
||||
} catch (swift::Error& e) {
|
||||
printf("Exception\n");
|
||||
}
|
||||
try {
|
||||
Functions::throwFunctionWithReturn();
|
||||
} catch (swift::_impl::swift::Error& e) {
|
||||
} catch (swift::Error& e) {
|
||||
printf("Exception\n");
|
||||
}
|
||||
try {
|
||||
Functions::testDestroyedError();
|
||||
} catch(const swift::Error &e) { }
|
||||
|
||||
return 0;
|
||||
}
|
||||
@@ -43,3 +46,4 @@ int main() {
|
||||
// CHECK-NEXT: Exception
|
||||
// CHECK-NEXT: passThrowFunctionWithReturn
|
||||
// CHECK-NEXT: Exception
|
||||
// CHECK-NEXT: Test destroyed
|
||||
Reference in New Issue
Block a user