Commit ece46608 authored by Stefan Behnel's avatar Stefan Behnel

fix unknown name error

parent 288ebda9
......@@ -953,8 +953,10 @@ class InterpretCompilerDirectives(CythonTransform, SkipDeclarations):
if name == 'locals':
node.directive_locals = value
elif name != 'final':
self.context.nonfatal_error(PostParseError(dec.pos,
"Cdef functions can only take cython.locals() or final decorators, got %s." % name))
self.context.nonfatal_error(PostParseError(
node.pos,
"Cdef functions can only take cython.locals() "
"or final decorators, got %s." % name))
body = Nodes.StatListNode(node.pos, stats=[node])
return self.visit_with_directives(body, directives)
......
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