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
Kirill Smelkov
cython
Commits
761f996c
Commit
761f996c
authored
May 26, 2019
by
Marcel Plch
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix compile error with 3.8
parent
93bf3a7d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
9 deletions
+13
-9
Cython/Utility/ModuleSetupCode.c
Cython/Utility/ModuleSetupCode.c
+5
-0
Cython/Utility/Profile.c
Cython/Utility/Profile.c
+8
-9
No files found.
Cython/Utility/ModuleSetupCode.c
View file @
761f996c
...
@@ -381,8 +381,13 @@ class __Pyx_FakeReference {
...
@@ -381,8 +381,13 @@ class __Pyx_FakeReference {
#define __Pyx_DefaultClassType PyClass_Type
#define __Pyx_DefaultClassType PyClass_Type
#else
#else
#define __Pyx_BUILTIN_MODULE_NAME "builtins"
#define __Pyx_BUILTIN_MODULE_NAME "builtins"
#if PY_VERSION_HEX < 0x030800A4
#define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos) \
#define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos) \
PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
#else
#define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos) \
PyCode_New(a, 0, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
#endif
#define __Pyx_DefaultClassType PyType_Type
#define __Pyx_DefaultClassType PyType_Type
#endif
#endif
...
...
Cython/Utility/Profile.c
View file @
761f996c
...
@@ -293,20 +293,18 @@ static PyCodeObject *__Pyx_createFrameCodeObject(const char *funcname, const cha
...
@@ -293,20 +293,18 @@ static PyCodeObject *__Pyx_createFrameCodeObject(const char *funcname, const cha
PyObject
*
py_funcname
=
0
;
PyObject
*
py_funcname
=
0
;
PyCodeObject
*
py_code
=
0
;
PyCodeObject
*
py_code
=
0
;
#if PY_MAJOR_VERSION < 3
#if PY_MAJOR_VERSION >= 3
py_code
=
PyCode_NewEmpty
(
srcfile
,
funcname
,
firstlineno
);
// make CPython use a fresh dict for "f_locals" at need (see GH #1836)
py_code
->
co_flags
|=
CO_OPTIMIZED
|
CO_NEWLOCALS
;
#else
py_funcname
=
PyString_FromString
(
funcname
);
py_funcname
=
PyString_FromString
(
funcname
);
py_srcfile
=
PyString_FromString
(
srcfile
);
py_srcfile
=
PyString_FromString
(
srcfile
);
#else
py_funcname
=
PyUnicode_FromString
(
funcname
);
py_srcfile
=
PyUnicode_FromString
(
srcfile
);
#endif
if
(
!
py_funcname
|
!
py_srcfile
)
goto
bad
;
py_code
=
PyCode_New
(
py_code
=
PyCode_New
(
0
,
/*int argcount,*/
0
,
/*int argcount,*/
#if PY_MAJOR_VERSION >= 3
0
,
/*int kwonlyargcount,*/
#endif
0
,
/*int nlocals,*/
0
,
/*int nlocals,*/
0
,
/*int stacksize,*/
0
,
/*int stacksize,*/
// make CPython use a fresh dict for "f_locals" at need (see GH #1836)
// make CPython use a fresh dict for "f_locals" at need (see GH #1836)
...
@@ -326,6 +324,7 @@ static PyCodeObject *__Pyx_createFrameCodeObject(const char *funcname, const cha
...
@@ -326,6 +324,7 @@ static PyCodeObject *__Pyx_createFrameCodeObject(const char *funcname, const cha
bad:
bad:
Py_XDECREF
(
py_srcfile
);
Py_XDECREF
(
py_srcfile
);
Py_XDECREF
(
py_funcname
);
Py_XDECREF
(
py_funcname
);
#endif
return
py_code
;
return
py_code
;
}
}
...
...
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