|
@@ -8,7 +8,9 @@
|
|
struct BadReturn {
|
|
struct BadReturn {
|
|
BadReturn(MyClass * myObject);
|
|
BadReturn(MyClass * myObject);
|
|
int bar(MyClass * myObject);
|
|
int bar(MyClass * myObject);
|
|
|
|
+ void MemFunc(MyClass * myObject);
|
|
int i;
|
|
int i;
|
|
|
|
+ MyClass *CObj;
|
|
};
|
|
};
|
|
|
|
|
|
@implementation MyClass
|
|
@implementation MyClass
|
|
@@ -21,12 +23,29 @@ int BadReturn::bar(MyClass * myObject) {
|
|
return 0;
|
|
return 0;
|
|
}
|
|
}
|
|
|
|
|
|
-BadReturn::BadReturn(MyClass * myObject) try {
|
|
|
|
|
|
+BadReturn::BadReturn(MyClass * myObject) try : CObj(myObject) {
|
|
} catch(...) {
|
|
} catch(...) {
|
|
try {
|
|
try {
|
|
[myObject privateMethod];
|
|
[myObject privateMethod];
|
|
[myObject privateMethod1];
|
|
[myObject privateMethod1];
|
|
getMe = bar(myObject);
|
|
getMe = bar(myObject);
|
|
|
|
+ [CObj privateMethod1];
|
|
|
|
+ } catch(int ei) {
|
|
|
|
+ i = ei;
|
|
|
|
+ } catch(...) {
|
|
|
|
+ {
|
|
|
|
+ i = 0;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+void BadReturn::MemFunc(MyClass * myObject) try {
|
|
|
|
+} catch(...) {
|
|
|
|
+ try {
|
|
|
|
+ [myObject privateMethod];
|
|
|
|
+ [myObject privateMethod1];
|
|
|
|
+ getMe = bar(myObject);
|
|
|
|
+ [CObj privateMethod1];
|
|
} catch(int ei) {
|
|
} catch(int ei) {
|
|
i = ei;
|
|
i = ei;
|
|
} catch(...) {
|
|
} catch(...) {
|