Skip to content

Commit

Permalink
move _depwarn
Browse files Browse the repository at this point in the history
# Conflicts:
#	src/ColorVectorSpace.jl
  • Loading branch information
t-bltg committed Feb 10, 2023
1 parent e74c2e6 commit 8965a41
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/ColorVectorSpace.jl
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,6 @@ export RGBRGB, complement, nan, dotc, dot, ⋅, hadamard, ⊙, tensor, ⊗, norm

MathTypes{T,C<:Union{AbstractGray{T},AbstractRGB{T}}} = Union{C,TransparentColor{C,T}}

if Base.VERSION >= v"1.5"
@inline _depwarn(msg, funcsym; force=false) = Base.depwarn(msg, funcsym; force=force)
else
@inline _depwarn(msg, funcsym; force=false) = Base.depwarn(msg, funcsym)
end

## Version compatibility with ColorTypes
### TODO: Remove the definitons other than `one` when dropping ColorTypes v0.10 support

Expand Down Expand Up @@ -492,6 +486,12 @@ module Future
channelwise intensity.
"""

if VERSION >= v"1.5"
@inline _depwarn(msg, funcsym; force=false) = Base.depwarn(msg, funcsym; force=force)
else
@inline _depwarn(msg, funcsym; force=false) = Base.depwarn(msg, funcsym)
end

function abs2(c::Union{Real,AbstractGray,AbstractRGB})
_depwarn("""
The return value of `abs2` has been changed to ensure that `abs2(g::Gray) ≈ abs2(RGB(g::Gray))`.
Expand Down

0 comments on commit 8965a41

Please sign in to comment.