From 3a79623c48e12762c996eb692cc5f45c349f5e8b Mon Sep 17 00:00:00 2001 From: kalmar Date: Wed, 21 Dec 2016 09:57:32 +0100 Subject: [PATCH] DomainError -> ArgumentError as the former don't accept message --- GroupAlgebras.jl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/GroupAlgebras.jl b/GroupAlgebras.jl index e1740f3..63fb94a 100644 --- a/GroupAlgebras.jl +++ b/GroupAlgebras.jl @@ -48,7 +48,7 @@ end (==)(X::GroupAlgebraElement, Y::GroupAlgebraElement) = isequal(X,Y) function add{T<:Number}(X::GroupAlgebraElement{T}, Y::GroupAlgebraElement{T}) - X.product_matrix == Y.product_matrix || throw(DomainError( + X.product_matrix == Y.product_matrix || throw(ArgumentError( "Elements don't seem to belong to the same Group Algebra!")) return GroupAlgebraElement(X.coordinates+Y.coordinates, X.product_matrix) end @@ -66,7 +66,7 @@ end function group_star_multiplication{T<:Number}(X::GroupAlgebraElement{T}, Y::GroupAlgebraElement{T}) - X.product_matrix == Y.product_matrix || DomainError( + X.product_matrix == Y.product_matrix || ArgumentError( "Elements don't seem to belong to the same Group Algebra!") result = zeros(X.coordinates) @@ -76,7 +76,7 @@ function group_star_multiplication{T<:Number}(X::GroupAlgebraElement{T}, else index = X.product_matrix[i,j] if index == 0 - throw(DomainError("The product don't seem to belong to the span of basis!")) + throw(ArgumentError("The product don't seem to belong to the span of basis!")) else result[index]+= x*y end