Skip to content

Commit 2c4688f

Browse files
author
Release Manager
committed
gh-36925: src/sage/calculus/ode.pyx: constness fix for clang 16 <!-- ^^^^^ Please provide a concise, informative and self-explanatory title. Don't put issue numbers in there, do this in the PR body below. For example, instead of "Fixes #1234" use "Introduce new method to calculate 1+1" --> <!-- Describe your changes here in detail --> - Fixes part of #36840 <!-- Why is this change required? What problem does it solve? --> <!-- If this PR resolves an open issue, please link to it here. For example "Fixes #12345". --> <!-- If your change requires a documentation PR, please link it appropriately. --> ### 📝 Checklist <!-- Put an `x` in all the boxes that apply. --> <!-- If your change requires a documentation PR, please link it appropriately --> <!-- If you're unsure about any of these, don't hesitate to ask. We're here to help! --> <!-- Feel free to remove irrelevant items. --> - [x] The title is concise, informative, and self-explanatory. - [ ] The description explains in detail what this PR is about. - [ ] I have linked a relevant issue or discussion. - [ ] I have created tests covering the changes. - [ ] I have updated the documentation accordingly. ### ⌛ Dependencies <!-- List all open PRs that this PR logically depends on - #12345: short description why this is a dependency - #34567: ... --> <!-- If you're unsure about any of these, don't hesitate to ask. We're here to help! --> URL: #36925 Reported by: Matthias Köppe Reviewer(s): Travis Scrimshaw
2 parents 980aa72 + dec6604 commit 2c4688f

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/sage/calculus/ode.pyx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -37,27 +37,27 @@ cdef class PyFunctionWrapper:
3737
self.y_n = x
3838

3939
cdef class ode_system:
40-
cdef int c_j(self,double t, double *y, double *dfdy,double *dfdt) noexcept: #void *params):
40+
cdef int c_j(self, double t, double *y, double *dfdy, double *dfdt) noexcept:
4141
return 0
4242

43-
cdef int c_f(self,double t, double* y, double* dydt) noexcept: #void *params):
43+
cdef int c_f(self, double t, double* y, double* dydt) noexcept:
4444
return 0
4545

46-
cdef int c_jac_compiled(double t, double *y, double *dfdy,double *dfdt, void * params) noexcept:
46+
cdef int c_jac_compiled(double t, const double *y, double *dfdy, double *dfdt, void *params) noexcept:
4747
cdef int status
4848
cdef ode_system wrapper
4949
wrapper = <ode_system> params
50-
status = wrapper.c_j(t,y,dfdy,dfdt) #Could add parameters
50+
status = wrapper.c_j(t, y, dfdy, dfdt) # Could add parameters
5151
return status
5252

53-
cdef int c_f_compiled(double t, double *y, double *dydt, void *params) noexcept:
53+
cdef int c_f_compiled(double t, const double *y, double *dydt, void *params) noexcept:
5454
cdef int status
5555
cdef ode_system wrapper
5656
wrapper = <ode_system> params
57-
status = wrapper.c_f(t,y,dydt) #Could add parameters
57+
status = wrapper.c_f(t, y, dydt) # Could add parameters
5858
return status
5959

60-
cdef int c_jac(double t,double *y,double *dfdy,double *dfdt,void *params) noexcept:
60+
cdef int c_jac(double t, const double *y, double *dfdy, double *dfdt, void *params) noexcept:
6161
cdef int i
6262
cdef int j
6363
cdef int y_n
@@ -84,7 +84,7 @@ cdef int c_jac(double t,double *y,double *dfdy,double *dfdt,void *params) noexce
8484
except Exception:
8585
return -1
8686

87-
cdef int c_f(double t,double* y, double* dydt,void *params) noexcept:
87+
cdef int c_f(double t, const double *y, double *dydt, void *params) noexcept:
8888
cdef int i
8989
cdef int y_n
9090
cdef int param_n

0 commit comments

Comments
 (0)