Skip to content

Commit 586720c

Browse files
authored
Remove unneded gray method (#137)
Fixes #124
1 parent 6cc5a50 commit 586720c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/ColorVectorSpace.jl

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,9 @@ for f in (:mod, :rem, :mod1)
7070
end
7171

7272
# Real values are treated like grays
73-
ColorTypes.gray(x::Real) = x
73+
if !hasmethod(gray, (Number,))
74+
ColorTypes.gray(x::Real) = x
75+
end
7476

7577
dotc(x::T, y::T) where {T<:Real} = acc(x)*acc(y)
7678
dotc(x::Real, y::Real) = dotc(promote(x, y)...)

0 commit comments

Comments
 (0)