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
5bd4c92e
Commit
5bd4c92e
authored
Jul 10, 2020
by
Xavier Thompson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adapt unit test to conform to new overload rules for cypclasses
parent
d29a8293
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
tests/run/cypclass_new_alloc.pyx
tests/run/cypclass_new_alloc.pyx
+4
-4
No files found.
tests/run/cypclass_new_alloc.pyx
View file @
5bd4c92e
...
...
@@ -29,13 +29,13 @@ def test_singleton():
cdef
cypclass
Base
:
double
value
__init__
(
self
,
int
a
):
self
.
value
=
(
<
double
>
a
)
*
1.2
__init__
(
self
,
int
a
,
double
b
):
self
.
value
=
(
<
double
>
a
)
*
b
__init__
(
self
,
double
b
):
self
.
value
=
b
Base
__new__
(
alloc
,
int
a
):
Base
__new__
(
alloc
,
int
a
,
double
b
):
return
alloc
()
cdef
cypclass
Derived
(
Base
):
...
...
@@ -48,7 +48,7 @@ def test_changing_init_choice():
6.0
5.0
"""
cdef
Base
base
=
Base
(
5
)
cdef
Base
base
=
Base
(
5
,
1.2
)
cdef
Derived
derived
=
Derived
(
5
)
print
base
.
value
print
derived
.
value
...
...
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