Skip to content

Commit 0bfcc52

Browse files
committed
Revert "Specialize one for the SizedArray test helper (#58209)"
This reverts commit 29bef40.
1 parent a4a6fff commit 0bfcc52

File tree

2 files changed

+0
-7
lines changed

2 files changed

+0
-7
lines changed

test/abstractarray.jl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1907,4 +1907,3 @@ end
19071907
@test r2[i] == z[j]
19081908
end
19091909
end
1910-

test/testhelpers/SizedArrays.jl

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,6 @@ Base.size(a::SizedArray) = size(typeof(a))
2929
Base.size(::Type{<:SizedArray{SZ}}) where {SZ} = SZ
3030
Base.getindex(A::SizedArray, i...) = getindex(A.data, i...)
3131
Base.zero(::Type{T}) where T <: SizedArray = SizedArray{size(T)}(zeros(eltype(T), size(T)))
32-
function Base.one(::Type{SizedMatrix{SZ,T,A}}) where {SZ,T,A}
33-
allequal(SZ) || throw(DimensionMismatch("multiplicative identity defined only for square matrices"))
34-
D = diagm(fill(one(T), SZ[1]))
35-
SizedArray{SZ}(convert(A, D))
36-
end
37-
Base.parent(S::SizedArray) = S.data
3832
+(S1::SizedArray{SZ}, S2::SizedArray{SZ}) where {SZ} = SizedArray{SZ}(S1.data + S2.data)
3933
==(S1::SizedArray{SZ}, S2::SizedArray{SZ}) where {SZ} = S1.data == S2.data
4034
function *(S1::SizedArray, S2::SizedArray)

0 commit comments

Comments
 (0)