From 5023b67269637ba06934494ebc2d9faf7eaeacba Mon Sep 17 00:00:00 2001 From: Stefan Behnel Date: Fri, 8 Feb 2013 00:07:20 +0100 Subject: [PATCH] provide fallback for cpdef functions that were previously called with full Python semantics --- Cython/Compiler/ExprNodes.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Cython/Compiler/ExprNodes.py b/Cython/Compiler/ExprNodes.py index ad75581..83e9684 100755 --- a/Cython/Compiler/ExprNodes.py +++ b/Cython/Compiler/ExprNodes.py @@ -4449,6 +4449,12 @@ class GeneralCallNode(CallNode): first_missing_keyword = name continue elif first_missing_keyword: + if entry.as_variable: + # we might be able to convert the function to a Python + # object, which then allows full calling semantics + # with default values in gaps - currently, we only + # support optional arguments at the end + return self # wasn't the last keyword => gaps are not supported error(self.pos, "C function call is missing " "argument '%s'" % first_missing_keyword) -- 2.7.4