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
b0511036
Commit
b0511036
authored
Jun 07, 2008
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Py3 test fixes
parent
d1d79cda
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
7 deletions
+12
-7
tests/run/big_indices.pyx
tests/run/big_indices.pyx
+3
-3
tests/run/modop.pyx
tests/run/modop.pyx
+9
-4
No files found.
tests/run/big_indices.pyx
View file @
b0511036
...
...
@@ -12,10 +12,10 @@ def test():
cdef
long
neg
=
-
1
cdef
unsigned
long
pos
=
-
2
# will be a large positive number
print
"neg"
,
neg
>
0
print
"pos"
,
pos
>
0
print
u
"neg"
,
neg
>
0
print
u
"pos"
,
pos
>
0
D
=
{
neg
:
'neg'
,
pos
:
'pos'
}
D
=
{
neg
:
u'neg'
,
pos
:
u
'pos'
}
print
D
[
<
object
>
neg
]
print
D
[
<
object
>
pos
]
...
...
tests/run/modop.pyx
View file @
b0511036
...
...
@@ -6,9 +6,14 @@ __doc__ = u"""
>>> modint(9,2)
1
"""
import
sys
if
sys
.
version_info
[
0
]
<
3
:
__doc__
=
__doc__
+
u"""
>>>
print
modptr()
spameggs
>>> modptr()
'spameggs'
"""
def
modobj
(
obj2
,
obj3
):
...
...
@@ -25,5 +30,5 @@ def modptr():
str2
=
"spam%s"
str3
=
"eggs"
obj1
=
str2
%
str3
return
obj1
.
decode
(
u"ASCII"
)
obj1
=
str2
%
str3
# '%' operator doesn't work on byte strings in Py3
return
obj1
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