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
b4c9ca28
Commit
b4c9ca28
authored
Jan 02, 2008
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tests for '**' operator
parent
9a8c817d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
4 deletions
+26
-4
tests/broken/powop.pyx
tests/broken/powop.pyx
+0
-4
tests/run/powop.pyx
tests/run/powop.pyx
+26
-0
No files found.
tests/broken/powop.pyx
deleted
100644 → 0
View file @
9a8c817d
def
f
(
obj1
,
obj2
,
obj3
):
cdef
float
flt1
,
flt2
,
flt3
flt1
=
flt2
**
flt3
obj1
=
obj2
**
obj3
tests/run/powop.pyx
0 → 100644
View file @
b4c9ca28
__doc__
=
"""
>>> f(1.0, 2.95)[0] == f(1.0, 2.95)[1]
True
>>> constant_py()
1024L
>>> constant_long() == 2L ** 36
True
"""
def
f
(
obj2
,
obj3
):
cdef
float
flt1
,
flt2
,
flt3
flt2
,
flt3
=
obj2
,
obj3
flt1
=
flt2
**
flt3
obj1
=
obj2
**
obj3
return
flt1
,
obj1
def
constant_py
():
result
=
2L
**
10
return
result
def
constant_long
():
result
=
2L
**
36
return
result
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