From ffee54616ab018150d1d3dd62d08571fee91d157 Mon Sep 17 00:00:00 2001 From: kalmar Date: Tue, 11 Jul 2017 18:28:30 +0200 Subject: [PATCH] critical fix: if g was not in basis setindex! failed silently --- src/GroupRings.jl | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/GroupRings.jl b/src/GroupRings.jl index 5d62b8f..d781f59 100644 --- a/src/GroupRings.jl +++ b/src/GroupRings.jl @@ -189,9 +189,8 @@ function setindex!(X::GroupRingElem, value, g::GroupElem) typeof(g) == elem_type(RG.group) || throw("$g is not an element of $(RG.group)") if !(g in keys(RG.basis_dict)) g = (RG.group)(g) - else - X.coeffs[RG.basis_dict[g]] = value end + X.coeffs[RG.basis_dict[g]] = value end Base.size(X::GroupRingElem) = size(X.coeffs)