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
a67d1a16
Commit
a67d1a16
authored
Dec 29, 2010
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Plain Diff
merged in latest cython-devel
parents
540dfa46
b4dd9bb5
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
1 deletion
+41
-1
tests/bugs.txt
tests/bugs.txt
+0
-1
tests/run/decorators_T593.pyx
tests/run/decorators_T593.pyx
+41
-0
No files found.
tests/bugs.txt
View file @
a67d1a16
...
@@ -18,7 +18,6 @@ ipow_crash_T562
...
@@ -18,7 +18,6 @@ ipow_crash_T562
pure_mode_cmethod_inheritance_T583
pure_mode_cmethod_inheritance_T583
genexpr_iterable_lookup_T600
genexpr_iterable_lookup_T600
for_from_pyvar_loop_T601
for_from_pyvar_loop_T601
decorators_T593
# CPython regression tests that don't current work:
# CPython regression tests that don't current work:
pyregr.test_threadsignals
pyregr.test_threadsignals
...
...
tests/run/decorators_T593.pyx
View file @
a67d1a16
...
@@ -24,6 +24,47 @@ def testclass(klass):
...
@@ -24,6 +24,47 @@ def testclass(klass):
class
Foo
:
class
Foo
:
pass
pass
def
class_in_closure
(
x
):
"""
>>> C1, c0 = class_in_closure(5)
>>> C1().smeth1()
(5, ())
>>> C1.smeth1(1,2)
(5, (1, 2))
>>> C1.smeth1()
(5, ())
>>> c0.smeth0()
1
>>> c0.__class__.smeth0()
1
"""
class
ClosureClass1
(
object
):
@
staticmethod
def
smeth1
(
*
args
):
return
x
,
args
class
ClosureClass0
(
object
):
@
staticmethod
def
smeth0
():
return
1
return
ClosureClass1
,
ClosureClass0
()
def
class_not_in_closure
():
"""
>>> c = class_not_in_closure()
>>> c.smeth0()
1
>>> c.__class__.smeth0()
1
"""
class
ClosureClass0
(
object
):
@
staticmethod
def
smeth0
():
return
1
return
ClosureClass0
()
class
ODict
(
dict
):
class
ODict
(
dict
):
def
__init__
(
self
):
def
__init__
(
self
):
dict
.
__init__
(
self
)
dict
.
__init__
(
self
)
...
...
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