X-Git-Url: http://gitweb.michael.orlitzky.com/?a=blobdiff_plain;f=src%2FCube.hs;h=4992851f3f7b3f7a3358e33852b53730c9269961;hb=631e653921937fe597090b66316227c9da14be35;hp=5a70afc70b5b4c02a0906e4c42620c7051cfb28e;hpb=2afb3f225800f5e7a27c9368b1391a0e16f206d6;p=spline3.git diff --git a/src/Cube.hs b/src/Cube.hs index 5a70afc..4992851 100644 --- a/src/Cube.hs +++ b/src/Cube.hs @@ -1,3 +1,8 @@ +-- The "tetrahedron" function pattern matches on the integers zero +-- through twenty-three, but doesn't handle the "otherwise" case, for +-- performance reasons. +{-# OPTIONS_GHC -Wno-incomplete-patterns #-} + module Cube ( Cube(..), cube_properties, @@ -15,7 +20,29 @@ import qualified Data.Vector as V ( singleton, snoc, unsafeIndex) -import Prelude hiding ( LT ) +import Prelude( + Bool, + Double, + Int, + Eq( (==) ), + Fractional( (/) ), + Maybe, + Num( (+), (-), (*) ), + Ord( (>=), (<=) ), + Show( show ), + ($), + (.), + (&&), + (++), + abs, + all, + and, + fromIntegral, + head, + map, + otherwise, + return, + tail ) import Test.Tasty ( TestTree, testGroup ) import Test.Tasty.QuickCheck ( Arbitrary( arbitrary ), @@ -24,7 +51,8 @@ import Test.Tasty.QuickCheck ( choose, testProperty ) import Cardinal ( - Cardinal(..), + Cardinal(F, B, L, R, D, T, FL, FR, FD, FT, + BL, BR, BD, BT, LD, LT, RD, RT, I), ccwx, ccwy, ccwz,