From: Michael Orlitzky Date: Tue, 5 Mar 2019 00:55:49 +0000 (-0500) Subject: src/RealFunction.hs: ignore orphan instance warnings. X-Git-Tag: 1.0.1~46 X-Git-Url: https://gitweb.michael.orlitzky.com/?a=commitdiff_plain;h=d3c559655599970d7e438701f6d780e49491c9d5;p=spline3.git src/RealFunction.hs: ignore orphan instance warnings. I'm pretty sure I don't want to make RealFunction a newtype, although I haven't tested the performance impact. But I definitely don't want to see these warnings. Use a pragma thingy to ignore them. --- diff --git a/src/RealFunction.hs b/src/RealFunction.hs index 307a0f0..37babf6 100644 --- a/src/RealFunction.hs +++ b/src/RealFunction.hs @@ -1,3 +1,4 @@ +{-# OPTIONS_GHC -Wno-orphans #-} {-# LANGUAGE FlexibleInstances #-} module RealFunction ( @@ -6,7 +7,9 @@ module RealFunction ( fexp ) where - +-- Presumably this is faster without a newtype wrapper, and that's why +-- we're about to define a bunch of orphan instances below. Note the +-- GHC pragma thingy at the top of this file to ignore those warnings. type RealFunction a = (a -> Double)