From cd135319f65f40a554d864b2a878a4ef44043a98 Mon Sep 17 00:00:00 2001 From: Tom Smeding Date: Mon, 10 Nov 2025 22:31:56 +0100 Subject: hlint cleanup --- src/CHAD/ForwardAD.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/CHAD/ForwardAD.hs') diff --git a/src/CHAD/ForwardAD.hs b/src/CHAD/ForwardAD.hs index 7126e10..0ebc244 100644 --- a/src/CHAD/ForwardAD.hs +++ b/src/CHAD/ForwardAD.hs @@ -7,6 +7,7 @@ module CHAD.ForwardAD where import Data.Bifunctor (bimap) +import Data.Foldable (fold) import System.IO.Unsafe -- import Debug.Trace @@ -89,7 +90,7 @@ tanScalars (STLEither a _) (Just (Left x)) = tanScalars a x tanScalars (STLEither _ b) (Just (Right y)) = tanScalars b y tanScalars (STMaybe _) Nothing = [] tanScalars (STMaybe t) (Just x) = tanScalars t x -tanScalars (STArr _ t) x = foldMap id $ arrayMap (tanScalars t) x +tanScalars (STArr _ t) x = fold $ arrayMap (tanScalars t) x tanScalars (STScal STI32) _ = [] tanScalars (STScal STI64) _ = [] tanScalars (STScal STF32) x = [realToFrac x] -- cgit v1.2.3-70-g09d2