]> gitweb.michael.orlitzky.com - spline3.git/blobdiff - src/Cardinal.hs
Fix some warnings and hlint suggestions.
[spline3.git] / src / Cardinal.hs
index 42b1260bb13f72f530bd725fd89943da1c1d004f..9a5d025efa9c43537aba416491b4fb10fa8e2494 100644 (file)
@@ -54,7 +54,7 @@ instance Num Cardinal where
     x + y = Sum x y
     x - y = Difference x y
     x * y = Product x y
-    negate x = Product (Scalar (-1)) x
+    negate = Product (Scalar (-1))
     abs x = x
     signum x = x
     fromInteger x = Scalar (fromIntegral x)
@@ -64,7 +64,7 @@ instance Num Cardinal where
 --   take quotients of directions.
 instance Fractional Cardinal where
     x / y   = Quotient x y
-    recip x = Quotient (Scalar 1) x
+    recip = Quotient (Scalar 1)
     fromRational x = Scalar (fromRational x)