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
Boxiang Sun
cython
Commits
9262420f
Commit
9262420f
authored
Aug 03, 2008
by
Dag Sverre Seljebotn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed bug with BoolNode result_code
parent
c3676b48
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
1 deletion
+26
-1
Cython/Compiler/ExprNodes.py
Cython/Compiler/ExprNodes.py
+1
-1
tests/run/bint.pyx
tests/run/bint.pyx
+25
-0
No files found.
Cython/Compiler/ExprNodes.py
View file @
9262420f
...
@@ -628,7 +628,7 @@ class BoolNode(ConstNode):
...
@@ -628,7 +628,7 @@ class BoolNode(ConstNode):
return
self
.
value
return
self
.
value
def
calculate_result_code
(
self
):
def
calculate_result_code
(
self
):
return
int
(
self
.
value
)
return
str
(
int
(
self
.
value
)
)
class
NullNode
(
ConstNode
):
class
NullNode
(
ConstNode
):
type
=
PyrexTypes
.
c_null_ptr_type
type
=
PyrexTypes
.
c_null_ptr_type
...
...
tests/run/bint.pyx
0 → 100644
View file @
9262420f
"""
>>> call_test()
False
True
False
True
True
True
True
"""
cdef
test
(
bint
value
):
print
value
def
call_test
():
test
(
False
)
test
(
True
)
test
(
0
)
test
(
234
)
test
(
-
1
)
x
=
True
test
(
x
)
x
=
3242
test
(
x
)
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