Commit ca3f5c6f authored by Stefan Behnel's avatar Stefan Behnel

fix string typed compiler directives in Py3

parent c820c9aa
...@@ -439,7 +439,7 @@ class InterpretCompilerDirectives(CythonTransform, SkipDeclarations): ...@@ -439,7 +439,7 @@ class InterpretCompilerDirectives(CythonTransform, SkipDeclarations):
if kwds is not None or len(args) != 1 or not isinstance(args[0], StringNode): if kwds is not None or len(args) != 1 or not isinstance(args[0], StringNode):
raise PostParseError(dec.function.pos, raise PostParseError(dec.function.pos,
'The %s option takes one compile-time string argument' % optname) 'The %s option takes one compile-time string argument' % optname)
return (optname, args[0].value) return (optname, str(args[0].value))
elif optiontype is dict: elif optiontype is dict:
if len(args) != 0: if len(args) != 0:
raise PostParseError(dec.function.pos, raise PostParseError(dec.function.pos,
......
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