Commit d2de789d authored by Xavier Thompson's avatar Xavier Thompson

Add comment on usage of const declarators

parent 056bf494
...@@ -826,6 +826,8 @@ class CConstDeclaratorNode(CDeclaratorNode): ...@@ -826,6 +826,8 @@ class CConstDeclaratorNode(CDeclaratorNode):
child_attrs = ["base"] child_attrs = ["base"]
def analyse(self, base_type, env, nonempty=0, visibility=None, in_pxd=False): def analyse(self, base_type, env, nonempty=0, visibility=None, in_pxd=False):
# XXX base_type is always a pointer type since CConstDeclaratorNode is only used when
# parsing '* const <declarator>'. As such the check below is probably superfluous.
if base_type.is_pyobject: if base_type.is_pyobject:
error(self.pos, error(self.pos,
"Const base type cannot be a Python object") "Const base type cannot be a Python object")
......
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