Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
stevengj committed Dec 16, 2016
1 parent 643fe95 commit 731e052
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions test/arrayops.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1926,3 +1926,11 @@ using TestHelpers.OAs
@test accumulate(op, [10,20, 30]) == [10, op(10, 20), op(op(10, 20), 30)] == [10, 40, 110]
@test accumulate(op, [10 20 30], 2) == [10 op(10, 20) op(op(10, 20), 30)] == [10 40 110]
end

# issue #11053
type T11053
a::Float64
end
Base.:*(a::T11053, b::Real) = T11053(a.a*b)
Base.:(==)(a::T11053, b::T11053) = a.a == b.a
@test [T11053(1)] * 5 == [T11053(1)] .* 5 == [T11053(5.0)]

0 comments on commit 731e052

Please sign in to comment.