Ticket #3724: m4ri_hash2.patch
| File m4ri_hash2.patch, 1.0 kB (added by malb, 4 months ago) |
|---|
-
a/sage/matrix/matrix_mod2_dense.pyx
old new 287 287 288 288 TEST: 289 289 sage: A = matrix(GF(2),2,0) 290 sage: hash(A) 291 Traceback (most recent call last): 292 ... 293 TypeError: mutable matrices are unhashable 290 294 sage: A.set_immutable() 291 295 sage: hash(A) 292 296 0 297 293 298 """ 299 if self.is_mutable(): 300 raise TypeError("mutable matrices are unhashable") 294 301 cdef unsigned long _hash = 0xDEADBEEF 295 302 cdef unsigned long counter = 0 296 303 cdef unsigned long i, j, truerow