diff options
Diffstat (limited to 'python/typearchive.py')
| -rw-r--r-- | python/typearchive.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/python/typearchive.py b/python/typearchive.py index b94cd62e..d7071978 100644 --- a/python/typearchive.py +++ b/python/typearchive.py @@ -234,7 +234,7 @@ class TypeArchive: def add_types(self, new_types: List[Tuple['_types.QualifiedNameType', '_types.Type']]) -> None: """ Add named types to the type archive. Types must have all dependent named - types added prior to the parent types being added (or included in the list) or this + types added prior to the parent types being added (or included in the list) or this function will fail. Types already existing with any added names will be overwritten. :param new_types: Names and definitions of new types @@ -801,25 +801,25 @@ class TypeArchiveNotificationCallbacks: def _type_added(self, ctxt, archive: ctypes.POINTER(core.BNTypeArchive), id: ctypes.c_char_p, definition: ctypes.POINTER(core.BNType)) -> None: try: self._notify.type_added(self._archive, core.pyNativeStr(id), _types.Type.create(handle=core.BNNewTypeReference(definition))) - except: + except Exception: log.log_error_for_exception("Unhandled Python exception in TypeArchiveNotificationCallbacks._type_added") def _type_updated(self, ctxt, archive: ctypes.POINTER(core.BNTypeArchive), id: ctypes.c_char_p, old_definition: ctypes.POINTER(core.BNType), new_definition: ctypes.POINTER(core.BNType)) -> None: try: self._notify.type_updated(self._archive, core.pyNativeStr(id), _types.Type.create(handle=core.BNNewTypeReference(old_definition)), _types.Type.create(handle=core.BNNewTypeReference(new_definition))) - except: + except Exception: log.log_error_for_exception("Unhandled Python exception in TypeArchiveNotificationCallbacks._type_updated") def _type_renamed(self, ctxt, archive: ctypes.POINTER(core.BNTypeArchive), id: ctypes.c_char_p, old_name: ctypes.POINTER(core.BNQualifiedName), new_name: ctypes.POINTER(core.BNQualifiedName)) -> None: try: self._notify.type_renamed(self._archive, core.pyNativeStr(id), _types.QualifiedName._from_core_struct(old_name.contents), _types.QualifiedName._from_core_struct(new_name.contents)) - except: + except Exception: log.log_error_for_exception("Unhandled Python exception in TypeArchiveNotificationCallbacks._type_renamed") def _type_deleted(self, ctxt, archive: ctypes.POINTER(core.BNTypeArchive), id: ctypes.c_char_p, definition: ctypes.POINTER(core.BNType)) -> None: try: self._notify.type_deleted(self._archive, core.pyNativeStr(id), _types.Type.create(handle=core.BNNewTypeReference(definition))) - except: + except Exception: log.log_error_for_exception("Unhandled Python exception in TypeArchiveNotificationCallbacks._type_deleted") @property |
