From 829a4edd2abb7026390d107c58b7b86d2c7a8757 Mon Sep 17 00:00:00 2001 From: Jarrett Revels Date: Mon, 26 Mar 2018 12:52:49 -0400 Subject: [PATCH] remove redundant abs definition post-DiffRules v0.0.4 --- REQUIRE | 2 +- src/dual.jl | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/REQUIRE b/REQUIRE index 4c47619c..243a8522 100644 --- a/REQUIRE +++ b/REQUIRE @@ -2,7 +2,7 @@ julia 0.6.0 Compat 0.47.0 StaticArrays 0.5.0 DiffResults 0.0.1 -DiffRules 0.0.3 +DiffRules 0.0.4 NaNMath 0.2.2 SpecialFunctions 0.1.0 CommonSubexpressions 0.0.1 diff --git a/src/dual.jl b/src/dual.jl index 83e93f87..2a94bf9b 100644 --- a/src/dual.jl +++ b/src/dual.jl @@ -318,8 +318,6 @@ Base.AbstractFloat(d::Dual{T,V,N}) where {T,V,N} = convert(Dual{T,promote_type(V @inline Base.conj(d::Dual) = d -@inline Base.abs(d::Dual) = signbit(value(d)) ? -d : d - for (M, f, arity) in DiffRules.diffrules() in((M, f), ((:Base, :^), (:NaNMath, :pow), (:Base, :/), (:Base, :+), (:Base, :-))) && continue if arity == 1