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
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Gwenaël Samain
cython
Commits
6b1a58c9
Commit
6b1a58c9
authored
Jun 16, 2014
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
extend tests for new generator properties
parent
4716e1e7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
28 additions
and
0 deletions
+28
-0
tests/run/generators.pyx
tests/run/generators.pyx
+28
-0
No files found.
tests/run/generators.pyx
View file @
6b1a58c9
...
@@ -55,6 +55,34 @@ def attributes():
...
@@ -55,6 +55,34 @@ def attributes():
'<lambda>'
'<lambda>'
>>> y.__qualname__
>>> y.__qualname__
'attributes.<locals>.inner.<locals>.<lambda>'
'attributes.<locals>.inner.<locals>.<lambda>'
>>> y.__name__ = 123
Traceback (most recent call last):
TypeError: __name__ must be set to a string object
>>> y.__name__
'<lambda>'
>>> y.__qualname__ = None
Traceback (most recent call last):
TypeError: __qualname__ must be set to a string object
>>> y.__qualname__
'attributes.<locals>.inner.<locals>.<lambda>'
>>> y.__name__ = 'abc'
>>> y.__name__
'abc'
>>> y.__name__ = None
Traceback (most recent call last):
TypeError: __name__ must be set to a string object
>>> y.__name__
'abc'
>>> y.__qualname__ = 'huhu'
>>> y.__qualname__
'huhu'
>>> y.__qualname__ = 123
Traceback (most recent call last):
TypeError: __qualname__ must be set to a string object
>>> y.__qualname__
'huhu'
"""
"""
def
inner
():
def
inner
():
return
(
lambda
:
(
yield
1
))
return
(
lambda
:
(
yield
1
))
...
...
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