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
46d3efc4
Commit
46d3efc4
authored
May 17, 2016
by
Robert Bradshaw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Work around missing Cygwin truncl.
parent
c9756622
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
Cython/Compiler/Optimize.py
Cython/Compiler/Optimize.py
+6
-1
Cython/Utility/ModuleSetupCode.c
Cython/Utility/ModuleSetupCode.c
+6
-0
No files found.
Cython/Compiler/Optimize.py
View file @
46d3efc4
...
...
@@ -2085,8 +2085,13 @@ class OptimizeBuiltinCalls(Visitor.NodeRefCleanupMixin,
elif
node
.
type
.
assignable_from
(
func_arg
.
type
)
or
func_arg
.
type
.
is_float
:
return
ExprNodes
.
TypecastNode
(
node
.
pos
,
operand
=
func_arg
,
type
=
node
.
type
)
elif
func_arg
.
type
.
is_float
and
node
.
type
.
is_numeric
:
if
func_arg
.
type
.
math_h_modifier
==
'l'
:
# Work around missing Cygwin definition.
truncl
=
'__Pyx_truncl'
else
:
truncl
=
'trunc'
+
func_arg
.
type
.
math_h_modifier
return
ExprNodes
.
PythonCapiCallNode
(
node
.
pos
,
'trunc'
+
func_arg
.
type
.
math_h_modifier
,
node
.
pos
,
truncl
,
func_type
=
self
.
float_float_func_types
[
func_arg
.
type
],
args
=
[
func_arg
],
py_name
=
'int'
,
...
...
Cython/Utility/ModuleSetupCode.c
View file @
46d3efc4
...
...
@@ -316,6 +316,12 @@ static CYTHON_INLINE float __PYX_NAN() {
}
#endif
#if defined(__CYGWIN__) && defined(_LDBL_EQ_DBL)
#define __Pyx_truncl trunc
#else
#define __Pyx_truncl truncl
#endif
/////////////// UtilityFunctionPredeclarations.proto ///////////////
...
...
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