@@ -4765,14 +4765,10 @@ function vcat(a::AbstractAlgebra.MatElem, b::AbstractAlgebra.MatElem)
47654765end
47664766
47674767@doc Markdown. doc"""
4768- vcat(A::Vector{<: MatrixElem} ) -> MatrixElem
4769- > Return the horizontal concatenation of the matrices in $A $.
4768+ vcat(A::MatrixElem... ) -> MatrixElem
4769+ > Return the horizontal concatenation of the matrices $A $.
47704770> All component matrices need to have the same base ring and number of columns.
47714771"""
4772- function vcat (A:: Vector{<: MatrixElem} )
4773- return _vcat (A)
4774- end
4775-
47764772function Base. vcat (A:: MatrixElem... )
47774773 return _vcat (A)
47784774end
@@ -4785,7 +4781,7 @@ function _vcat(A)
47854781 if any (x -> ncols (x) != ncols (A[1 ]), A)
47864782 error (" Matrices must have the same number of columns" )
47874783 end
4788-
4784+
47894785 if any (x -> base_ring (x) != base_ring (A[1 ]), A)
47904786 error (" Matrices must have the same base ring" )
47914787 end
@@ -4804,23 +4800,23 @@ function _vcat(A)
48044800end
48054801
48064802@doc Markdown. doc"""
4807- hcat(A::Vector{<: MatrixElem} ) -> MatrixElem
4808- > Return the horizontal concatenating of the matrices in $A $.
4803+ hcat(A::MatrixElem... ) -> MatrixElem
4804+ > Return the horizontal concatenating of the matrices $A $.
48094805> All component matrices need to have the same base ring and number of rows.
48104806"""
4811- function hcat (A:: Vector{<: MatrixElem} )
4807+ function Base . hcat (A:: MatrixElem... )
48124808 return _hcat (A)
48134809end
48144810
48154811function _hcat (A)
48164812 if length (A) == 0
48174813 error (" Number of matrices to concatenate must be positive" )
48184814 end
4819-
4815+
48204816 if any (x -> nrows (x) != nrows (A[1 ]), A)
48214817 error (" Matrices must have the same number of rows" )
48224818 end
4823-
4819+
48244820 if any (x -> base_ring (x) != base_ring (A[1 ]), A)
48254821 error (" Matrices must have the same base ring" )
48264822 end
@@ -4838,14 +4834,10 @@ function _hcat(A)
48384834 return M
48394835end
48404836
4841- function Base. hcat (A:: MatrixElem... )
4842- return _hcat (A)
4843- end
4844-
4845- function Base. cat (A:: MatrixElem... ;dims)
4837+ function Base. cat (A:: MatrixElem... ;dims)
48464838 @assert dims == (1 ,2 ) || isa (dims, Int)
48474839
4848- if isa (dims, Int)
4840+ if isa (dims, Int)
48494841 if dims == 1
48504842 return hcat (A... )
48514843 elseif dims == 2
0 commit comments