Changes

Jump to: navigation, search

Obj-C Exceptions In Gecko

5 bytes added, 22:47, 10 July 2007
1.8 branch
= Possible solutions =
== Gecko 1.8 branch ==Since there isn't a whole lot of code that's using Cocoa on in Gecko 1.8, it might be best to to write macros to wrap any XPCOM entry point that calls cocoa, start to finish. NS_OBJC_EXCEPTION_CATCHER_START and _END, for example.
Another, eviler approach is to override NSException's initWithName:reason:userInfo: method to instead call some sort of assertion, and then return nil. This of course bypasses the entire ObjC exception system, and will horribly, horribly break any code that depends upon actually handling ObjC exceptions. There might still some merit in the idea of posing as NSException, perhaps to override -raise?
Confirm, emeritus
1,680
edits

Navigation menu