mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2026-01-05 19:40:12 +01:00
More Python3 fixes
This commit is contained in:
@@ -1960,7 +1960,7 @@ class XMLDocString(object):
|
|||||||
else:
|
else:
|
||||||
raise Exception('Unhandled docstring kind for %s'%xml_item.__class__.__name__)
|
raise Exception('Unhandled docstring kind for %s'%xml_item.__class__.__name__)
|
||||||
|
|
||||||
if hasattr(xml_item, 'deprecated') and xml_item.deprecated and isinstance(xml_item.deprecated, basestring):
|
if hasattr(xml_item, 'deprecated') and xml_item.deprecated and isinstance(xml_item.deprecated, string_base):
|
||||||
element = et.Element('deprecated', kind='deprecated')
|
element = et.Element('deprecated', kind='deprecated')
|
||||||
element.text = VERSION
|
element.text = VERSION
|
||||||
|
|
||||||
@@ -2610,7 +2610,7 @@ class XMLDocString(object):
|
|||||||
|
|
||||||
if hasattr(method, 'deprecated') and method.deprecated:
|
if hasattr(method, 'deprecated') and method.deprecated:
|
||||||
text = method.deprecated
|
text = method.deprecated
|
||||||
if isinstance(text, basestring):
|
if isinstance(text, string_base):
|
||||||
text = '%s %s\n%s%s\n\n'%(' .. deprecated::', VERSION, ' '*9, text.replace('\n', ' '))
|
text = '%s %s\n%s%s\n\n'%(' .. deprecated::', VERSION, ' '*9, text.replace('\n', ' '))
|
||||||
stream.write(text)
|
stream.write(text)
|
||||||
|
|
||||||
|
|||||||
@@ -301,7 +301,7 @@ def PythonizeType(ptype, is_param):
|
|||||||
|
|
||||||
else:
|
else:
|
||||||
if is_param and '.' in ptype:
|
if is_param and '.' in ptype:
|
||||||
modules = MODULENAME_REPLACE.values()
|
modules = list(MODULENAME_REPLACE.values())
|
||||||
modules.sort()
|
modules.sort()
|
||||||
modules = modules[1:]
|
modules = modules[1:]
|
||||||
if ptype.split('.')[0] + '.' in modules:
|
if ptype.split('.')[0] + '.' in modules:
|
||||||
|
|||||||
Reference in New Issue
Block a user