diff options
| author | Glenn Smith <glenn@vector35.com> | 2024-05-31 18:31:09 -0400 |
|---|---|---|
| committer | Glenn Smith <glenn@vector35.com> | 2024-06-04 00:29:49 -0400 |
| commit | 4152126289652104982292308858511197568097 (patch) | |
| tree | 1f1def136b994e7746b6fe650963d151da209cf8 /python/typeprinter.py | |
| parent | 6520026964065327558472841838510176646568 (diff) | |
Add CorePlatform to python api for proper subclassing
Diffstat (limited to 'python/typeprinter.py')
| -rw-r--r-- | python/typeprinter.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/python/typeprinter.py b/python/typeprinter.py index aea598b3..e9e085c6 100644 --- a/python/typeprinter.py +++ b/python/typeprinter.py @@ -117,7 +117,7 @@ class TypePrinter(metaclass=_TypePrinterMetaclass): try: platform_py = None if platform: - platform_py = _platform.Platform(handle=core.BNNewPlatformReference(platform)) + platform_py = _platform.CorePlatform._from_cache(handle=core.BNNewPlatformReference(platform)) result_py = self.get_type_tokens( types.Type.create(handle=core.BNNewTypeReference(type)), platform_py, types.QualifiedName._from_core_struct(name.contents), base_confidence, escaping) @@ -135,7 +135,7 @@ class TypePrinter(metaclass=_TypePrinterMetaclass): try: platform_py = None if platform: - platform_py = _platform.Platform(handle=core.BNNewPlatformReference(platform)) + platform_py = _platform.CorePlatform._from_cache(handle=core.BNNewPlatformReference(platform)) parent_type_py = None if parent_type: parent_type_py = types.Type.create(handle=core.BNNewTypeReference(parent_type)) @@ -156,7 +156,7 @@ class TypePrinter(metaclass=_TypePrinterMetaclass): try: platform_py = None if platform: - platform_py = _platform.Platform(handle=core.BNNewPlatformReference(platform)) + platform_py = _platform.CorePlatform._from_cache(handle=core.BNNewPlatformReference(platform)) parent_type_py = None if parent_type: parent_type_py = types.Type.create(handle=core.BNNewTypeReference(parent_type)) @@ -177,7 +177,7 @@ class TypePrinter(metaclass=_TypePrinterMetaclass): try: platform_py = None if platform: - platform_py = _platform.Platform(handle=core.BNNewPlatformReference(platform)) + platform_py = _platform.CorePlatform._from_cache(handle=core.BNNewPlatformReference(platform)) result_py = self.get_type_string( types.Type.create(handle=core.BNNewTypeReference(type)), platform_py, types.QualifiedName._from_core_struct(name.contents), escaping) @@ -193,7 +193,7 @@ class TypePrinter(metaclass=_TypePrinterMetaclass): try: platform_py = None if platform: - platform_py = _platform.Platform(handle=core.BNNewPlatformReference(platform)) + platform_py = _platform.CorePlatform._from_cache(handle=core.BNNewPlatformReference(platform)) result_py = self.get_type_string_before_name( types.Type.create(handle=core.BNNewTypeReference(type)), platform_py, escaping) @@ -209,7 +209,7 @@ class TypePrinter(metaclass=_TypePrinterMetaclass): try: platform_py = None if platform: - platform_py = _platform.Platform(handle=core.BNNewPlatformReference(platform)) + platform_py = _platform.CorePlatform._from_cache(handle=core.BNNewPlatformReference(platform)) result_py = self.get_type_string_after_name( types.Type.create(handle=core.BNNewTypeReference(type)), platform_py, escaping) |
