diff --git a/src/matrix.cc b/src/matrix.cc index 6e84f19..7119f02 100644 --- a/src/matrix.cc +++ b/src/matrix.cc @@ -83,8 +83,8 @@ Obj Func_SI_bigintmat(Obj self, Obj m) // TODO: get rid of _SI_Matbigintmat and use SI_ToGAP instead ? Obj Func_SI_Matbigintmat(Obj self, Obj im) { - // TODO: This function is untested! add test cases!!! - if (!ISSINGOBJ(SINGTYPE_BIGINTMAT_IMM,im)) { + if (!(ISSINGOBJ(SINGTYPE_BIGINTMAT_IMM,im) || + ISSINGOBJ(SINGTYPE_BIGINTMAT,im))) { ErrorQuit("im must be a singular bigintmat", 0L, 0L); return Fail; } diff --git a/tst/matelm.tst b/tst/matelm.tst index 6690072..db765e2 100644 --- a/tst/matelm.tst +++ b/tst/matelm.tst @@ -18,7 +18,7 @@ gap> gap> gap> gap> m2 := SI_bigintmat([[1,2,3],[4,5,6]] * 7^15); - gap> _SI_MatElm(m2, 1, 3); 14242684529829