try to coerce before throwing error

This commit is contained in:
kalmar 2017-05-18 21:49:12 +02:00
parent 45fc421da7
commit 27e9ce254f
1 changed files with 0 additions and 1 deletions

View File

@ -107,7 +107,6 @@ function (RG::GroupRing)(T::Type=Int)
end
function (RG::GroupRing)(g::GroupElem, T::Type=Int)
typeof(g) == elem_type(RG.group) || throw("$g does not belong to $(RG.group), the underlying group of $RG")
g = try
RG.group(g)
catch