Commits

Anonymous committed 9d4e446

added #define to override bug in Python-2.2 abstract.h
wrapped code that was causing uncaught exception, but
the same sort of things will still bomb out with BusErr
after exception is caught.

  • Participants
  • Parent commits 32a979b

Comments (0)

Files changed (1)

pyobjc/OC_PythonObject.m

 
 #include "objc_support.h"
 #include "abstract.h"
+/* the def below is to fix Python2.2 bug */
+#define PyMapping_DelItem(O,K) PyDict_DelItem((O),(K))
 #include "compile.h"
 
 #include <stdarg.h>
 
 - (NSMethodSignature *) methodSignatureForSelector:(SEL) sel
 {
-  NSMethodSignature *result = [super methodSignatureForSelector:sel];
+
+  NSMethodSignature *result;
+
+  NS_DURING
+    result = [super methodSignatureForSelector:sel];
+  NS_HANDLER
+    result = nil;
+    NSLog( [localException name]);
+    NSLog( [localException reason] );
+  NS_ENDHANDLER
   
   if (!result)
     {