Commit f73884c3 authored by Stefan Behnel's avatar Stefan Behnel

fix condition to make struct conversion generate struct field conversion helpers at need

--HG--
extra : amend_source : 240f49031159777036e1e6a139b6d736f59de337
parent 219725ca
......@@ -2842,7 +2842,7 @@ class CStructOrUnionType(CType):
if self._convert_to_py_code is None:
for member in self.scope.var_entries:
if not member.type.to_py_function or not member.type.create_to_py_utility_code(env):
if not member.type.to_py_function and not member.type.create_to_py_utility_code(env):
self.to_py_function = None
self._convert_to_py_code = False
return False
......@@ -2860,7 +2860,7 @@ class CStructOrUnionType(CType):
if self._convert_from_py_code is None:
for member in self.scope.var_entries:
if (not member.type.from_py_function or not
if (not member.type.from_py_function and not
member.type.create_from_py_utility_code(env)):
self.from_py_function = None
self._convert_from_py_code = False
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment