Skip to content

Commit

Permalink
sagemath#38960 fix eclib interface after upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnCremona committed Nov 19, 2024
1 parent f152ea3 commit 28c0400
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/sage/libs/eclib/__init__.pxd
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ cdef extern from "eclib/matrix.h":
cdef cppclass mat:
mat()
mat(mat m)
scalar* get_entries()
vector[scalar] get_entries()
scalar sub(long, long)
long nrows()
long ncols()
Expand All @@ -67,7 +67,7 @@ cdef extern from "eclib/smatrix.h":
cdef cppclass smat:
smat()
smat(smat m)
scalar* get_entries()
vector[scalar] get_entries()
scalar sub(long, long)
long nrows()
long ncols()
Expand Down
4 changes: 2 additions & 2 deletions src/sage/libs/eclib/mat.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ from sage.rings.integer_ring import ZZ
from sage.matrix.matrix_integer_sparse cimport Matrix_integer_sparse
from sage.matrix.matrix_integer_dense cimport Matrix_integer_dense
from sage.rings.integer cimport Integer

from libcpp.vector cimport vector

cdef class Matrix:
"""
Expand Down Expand Up @@ -213,7 +213,7 @@ cdef class Matrix:
"""
cdef long n = self.nrows()
cdef long i, j, k
cdef scalar* v = <scalar*> self.M.get_entries() # coercion needed to deal with const
cdef vector[scalar] v = <vector[scalar]> self.M.get_entries() # coercion needed to deal with const

cdef Matrix_integer_dense Td
cdef Matrix_integer_sparse Ts
Expand Down

0 comments on commit 28c0400

Please sign in to comment.