summaryrefslogtreecommitdiff
path: root/src/PGF.hs
diff options
context:
space:
mode:
authorkrasimir <krasimir@chalmers.se>2009-09-06 20:31:52 +0000
committerkrasimir <krasimir@chalmers.se>2009-09-06 20:31:52 +0000
commitb97d6abb8190cdcb595b9bf48051cc4a98f01156 (patch)
tree744fc14acf55e09812f6e15bab831cd28c1e7187 /src/PGF.hs
parentc99b64404dd6b776d80b36ae3e1b8ef4e80949f7 (diff)
hopefully complete and correct typechecker in PGF
Diffstat (limited to 'src/PGF.hs')
-rw-r--r--src/PGF.hs11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/PGF.hs b/src/PGF.hs
index 8ac936e70..45da170d9 100644
--- a/src/PGF.hs
+++ b/src/PGF.hs
@@ -9,7 +9,7 @@
-- load and interpret grammars compiled in Portable Grammar Format (PGF).
-- The PGF format is produced as a final output from the GF compiler.
-- The API is meant to be used for embedding GF grammars in Haskell
--- programs.
+-- programs
-------------------------------------------------
module PGF(
@@ -51,7 +51,11 @@ module PGF(
parse, canParse, parseAllLang, parseAll,
-- ** Evaluation
- tree2expr, expr2tree, PGF.compute, paraphrase, typecheck,
+ tree2expr, expr2tree, PGF.compute, paraphrase,
+
+ -- ** Type Checking
+ checkType, checkExpr, inferExpr,
+ ppTcError, TcError(..),
-- ** Word Completion (Incremental Parsing)
complete,
@@ -80,6 +84,7 @@ import GF.Data.Utilities (replace)
import Data.Char
import qualified Data.Map as Map
+import qualified Data.IntMap as IntMap
import Data.Maybe
import Data.Binary
import System.Random (newStdGen)
@@ -307,4 +312,4 @@ complete pgf from typ input =
-- | Converts an expression to normal form
compute :: PGF -> Expr -> Expr
-compute pgf = PGF.Data.normalForm (funs (abstract pgf))
+compute pgf = PGF.Data.normalForm (funs (abstract pgf)) 0 []