|
| <prev next> |
Custom exceptions: msg#00360python.c++
So, let's say I want to register a custom exception which python code can catch, thusly: try: doSomething() except mymodule.MyException e: print e Is there anything in boost python that makes setting this up easy? I've got a working exception translator and everything, but I don't see anything equivalent to putting "PyErr_NewException("mymodule.MyException", NULL, NULL)" into the system dictionary during module initialization. Or am I just working too hard again? -- Gavin Doughtie DreamWorks SKG |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Attempted a typeid of NULL pointer!: 00360, Marcelo A. Camelo |
|---|---|
| Next by Date: | Re: Attempted a typeid of NULL pointer!: 00360, David Abrahams |
| Previous by Thread: | custom less than operator? to_python_converter for multiple destination types?i: 00360, Gavin Doughtie |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |