Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
nexedi
cython
Commits
d4df9dd0
Commit
d4df9dd0
authored
Sep 07, 2014
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
do not try to generated embedded signatures for lambda functions
parent
c238e5b0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
0 deletions
+8
-0
Cython/Compiler/AutoDocTransforms.py
Cython/Compiler/AutoDocTransforms.py
+4
-0
tests/run/embedsignatures.pyx
tests/run/embedsignatures.pyx
+4
-0
No files found.
Cython/Compiler/AutoDocTransforms.py
View file @
d4df9dd0
...
...
@@ -150,6 +150,10 @@ class EmbedSignature(CythonTransform):
self
.
class_node
=
oldclass
return
node
def
visit_LambdaNode
(
self
,
node
):
# lambda expressions so not have signature or inner functions
return
node
def
visit_DefNode
(
self
,
node
):
if
not
self
.
current_directives
[
'embedsignature'
]:
return
node
...
...
tests/run/embedsignatures.pyx
View file @
d4df9dd0
...
...
@@ -402,3 +402,7 @@ cpdef f_defexpr4(int x = (Ext.CONST1 + FLAG1) * Ext.CONST2):
cpdef
f_defexpr5
(
int
x
=
2
+
2
):
pass
# no signatures for lambda functions
lambda_foo
=
lambda
x
:
10
lambda_bar
=
lambda
x
:
20
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment