]> hydra-www.ietfng.org Git - dyna2/commitdiff
More cleanups and a forgotten file
authorNathaniel Wesley Filardo <nwf@cs.jhu.edu>
Fri, 29 Mar 2013 18:26:28 +0000 (14:26 -0400)
committerNathaniel Wesley Filardo <nwf@cs.jhu.edu>
Fri, 29 Mar 2013 18:26:28 +0000 (14:26 -0400)
README.md
dyna.cabal
src/Dyna/Term/TTerm.hs

index f74154c8e0c342c4066d2b29b2b4ddba54a5e8f3..75524ea1e6f2cbfed45f577ef019d21c75d706b4 100644 (file)
--- a/README.md
+++ b/README.md
@@ -19,18 +19,20 @@ An overview of the source tree
 Building
 --------
 
-First, ensure that you have GHC 7.6 or later.  (Though in a pinch, if you're
-only interested in the frontend stuff and the Python backend, apparently as
-early as 7.0 continues to be servicable.)
-
-Ensure that you have the Haskell platform available, either through your
-favorite package manager or by installing it stand-alone.  You should
-probably run
+First, ensure that you have the Haskell platform 2012.2 or later installed,
+either through your favorite package manager or by installing it
+stand-alone.  You should probably run
 
     cabal update
 
 before proceeding, just to make sure that your package database is
-up-to-date.  Then fetch, build, and install any dependencies (for the
+up-to-date.  Some of our transitive dependencies assume that you have
+`alex` and `happy` available -- either fetch those from your package manager
+or add `~/.cabal/bin` to your `PATH` and run
+
+    cabal install alex happy
+
+Then fetch, build, and install any dependencies (for the
 moment, we seem to be doing OK with vanilla upstreams!)
 
     make deps
index e00fe190d5eb6412855c47b5fef55214bc58aea9..c466502ed298e03f162ba5df74ec1ba5781c9fdb 100644 (file)
@@ -53,7 +53,6 @@ Library
                         template-haskell,
                         transformers >= 0.3,
                         trifecta >= 1.0,
-                        unification-fd,
                         unordered-containers>=0.2,
                         utf8-string >=0.3,
                         wl-pprint-extras >=3.0,
@@ -82,7 +81,6 @@ Executable drepl
                         tagged >= 0.4.4,
                         transformers >= 0.3,
                         trifecta >= 1.0,
-                        unification-fd,
                         unordered-containers>=0.2,
                         utf8-string >=0.3,
                         wl-pprint-extras >=3.0
@@ -114,7 +112,6 @@ Executable dyna
                         tagged >= 0.4.4,
                         transformers >= 0.3,
                         trifecta >= 1.0,
-                        unification-fd,
                         unordered-containers>=0.2,
                         utf8-string >=0.3,
                         wl-pprint-extras >=3.0,
@@ -153,7 +150,6 @@ Test-suite dyna-selftests
                         test-framework-golden >= 1.1,
                         transformers >= 0.3,
                         trifecta >= 1.0,
-                        unification-fd,
                         unordered-containers>=0.2,
                         utf8-string >=0.3,
                         wl-pprint-extras >=3.0
index 2ed6aadc8b5d776749ecfb0ddd97045aa72c1e5e..ca401c09eebc170a3a5ba1f183bedb42287a610f 100644 (file)
@@ -5,6 +5,7 @@
 -- complicated things, but it suffices for now?
 
 -- Header material                                                      {{{
+{-# LANGUAGE DeriveDataTypeable #-}
 {-# LANGUAGE DeriveFoldable #-}
 {-# LANGUAGE DeriveFunctor #-}
 {-# LANGUAGE DeriveTraversable #-}
@@ -21,17 +22,17 @@ module Dyna.Term.TTerm (
     TBase(..), TBaseSkolem(..),
 
         -- * Terms
-    TermF(..), DTermV, DVar, DFunct, DFunctAr, DTerm,
+    TermF(..), {- DTermV, -} DVar, DFunct, DFunctAr, {- DTerm, -}
 
         -- * Rules
     DAgg, {- DRule(..), -}
 
         -- * Convenience re-export
-    UTerm(..)
+    -- UTerm(..)
 ) where
 
-import           Control.Unification
 import qualified Data.ByteString       as B
+import qualified Data.Data             as D
 import qualified Data.Foldable         as F
 import qualified Data.Traversable      as T
 import qualified Text.PrettyPrint.Free as PP
@@ -39,15 +40,13 @@ import qualified Text.PrettyPrint.Free as PP
 ------------------------------------------------------------------------}}}
 -- Term Base Cases                                                      {{{
 
--- | Used in mode analysis to indicate that an inst is bound to a ground
--- (but unknown) value.
 data TBaseSkolem = TSNumeric | TSString
  deriving (Eq,Ord,Show)
 
 -- | Term base cases.
 data TBase = TNumeric !(Either Integer Double)
            | TString  !B.ByteString
- deriving (Eq,Ord,Show)
+ deriving (D.Data,D.Typeable,Eq,Ord,Show)
 
 instance PP.Pretty TBase where
     pretty (TNumeric (Left x))  = PP.pretty x
@@ -58,27 +57,27 @@ instance PP.Pretty TBase where
 -- Terms                                                                {{{
 
 data Annotation t = AnnType t
- deriving (Eq,F.Foldable,Functor,Ord,Show,T.Traversable)
+ deriving (D.Data,D.Typeable,Eq,F.Foldable,Functor,Ord,Show,T.Traversable)
 
 data TermF a t = TFunctor !a ![t]
-               | TBase TBase
+               | TBase !TBase
  deriving (Eq,F.Foldable,Functor,Ord,Show,T.Traversable)
 
 type DFunct = B.ByteString
 type DFunctAr = (DFunct,Int)
-type DTermV v = UTerm (TermF DFunct) v
 
 type DVar  = B.ByteString
-type DTerm = DTermV DVar
 
 ------------------------------------------------------------------------}}}
 -- Instances                                                            {{{
 
+{-
 instance (Eq a) => Unifiable (TermF a) where
   zipMatch (TFunctor a as) (TFunctor b bs) | a == b
                                              && length as == length bs
      = Just (TFunctor a (zipWith (\aa ba -> Right (aa,ba)) as bs))
   zipMatch _ _                                      = Nothing
+-}
 
 ------------------------------------------------------------------------}}}
 -- Rules                                                                {{{