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
63991515
Commit
63991515
authored
Jun 07, 2011
by
Lisandro Dalcin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixes for GCC -Wconversion
parent
438a61e1
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
4 deletions
+6
-4
Cython/Compiler/ExprNodes.py
Cython/Compiler/ExprNodes.py
+4
-2
Cython/Compiler/PyrexTypes.py
Cython/Compiler/PyrexTypes.py
+2
-2
No files found.
Cython/Compiler/ExprNodes.py
View file @
63991515
...
@@ -6927,7 +6927,9 @@ class CmpNode(object):
...
@@ -6927,7 +6927,9 @@ class CmpNode(object):
contains_utility_code
=
UtilityCode
(
contains_utility_code
=
UtilityCode
(
proto
=
"""
proto
=
"""
static CYTHON_INLINE long __Pyx_NegateNonNeg(long b) { return unlikely(b < 0) ? b : !b; }
static CYTHON_INLINE int __Pyx_NegateNonNeg(int b) {
return unlikely(b < 0) ? b : !b;
}
static CYTHON_INLINE PyObject* __Pyx_PyBoolOrNull_FromLong(long b) {
static CYTHON_INLINE PyObject* __Pyx_PyBoolOrNull_FromLong(long b) {
return unlikely(b < 0) ? NULL : __Pyx_PyBool_FromLong(b);
return unlikely(b < 0) ? NULL : __Pyx_PyBool_FromLong(b);
}
}
...
@@ -7052,7 +7054,7 @@ static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int eq
...
@@ -7052,7 +7054,7 @@ static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int eq
else
else
return (PyBytes_AS_STRING(s1)[0] != PyBytes_AS_STRING(s2)[0]);
return (PyBytes_AS_STRING(s1)[0] != PyBytes_AS_STRING(s2)[0]);
} else {
} else {
int result = memcmp(PyBytes_AS_STRING(s1), PyBytes_AS_STRING(s2), PyBytes_GET_SIZE(s1));
int result = memcmp(PyBytes_AS_STRING(s1), PyBytes_AS_STRING(s2),
(size_t)
PyBytes_GET_SIZE(s1));
return (equals == Py_EQ) ? (result == 0) : (result != 0);
return (equals == Py_EQ) ? (result == 0) : (result != 0);
}
}
} else if ((s1 == Py_None) & PyBytes_CheckExact(s2)) {
} else if ((s1 == Py_None) & PyBytes_CheckExact(s2)) {
...
...
Cython/Compiler/PyrexTypes.py
View file @
63991515
...
@@ -761,9 +761,9 @@ static CYTHON_INLINE %(type)s __Pyx_PyInt_As%(SignWord)s%(TypeName)s(PyObject* x
...
@@ -761,9 +761,9 @@ static CYTHON_INLINE %(type)s __Pyx_PyInt_As%(SignWord)s%(TypeName)s(PyObject* x
"can't convert negative value to %(type)s");
"can't convert negative value to %(type)s");
return (%(type)s)-1;
return (%(type)s)-1;
}
}
return PyLong_AsUnsigned%(TypeName)s(x);
return
(%(type)s)
PyLong_AsUnsigned%(TypeName)s(x);
} else {
} else {
return PyLong_As%(TypeName)s(x);
return
(%(type)s)
PyLong_As%(TypeName)s(x);
}
}
} else {
} else {
%(type)s val;
%(type)s val;
...
...
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