summaryrefslogtreecommitdiff
path: root/src/compiler/GF/Grammar/Grammar.hs
diff options
context:
space:
mode:
authorhallgren <hallgren@chalmers.se>2011-10-20 14:36:30 +0000
committerhallgren <hallgren@chalmers.se>2011-10-20 14:36:30 +0000
commited451653bd9fa4d835cb263c06d0ecb9133b9935 (patch)
treecf6cc1e56c5cac76d4c9fb6c09a6bad456e3c151 /src/compiler/GF/Grammar/Grammar.hs
parente5accc0d8d3c6d9cace9d4aff482ab285bf7e01b (diff)
Introduce an explicit error value in the Term type
This makes it easier to treat run-time errors (e.g. caused by calls to Predef.error) in a way that is more typical for a lazy functional language.
Diffstat (limited to 'src/compiler/GF/Grammar/Grammar.hs')
-rw-r--r--src/compiler/GF/Grammar/Grammar.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/compiler/GF/Grammar/Grammar.hs b/src/compiler/GF/Grammar/Grammar.hs
index 686164539..ae29ab6d5 100644
--- a/src/compiler/GF/Grammar/Grammar.hs
+++ b/src/compiler/GF/Grammar/Grammar.hs
@@ -161,7 +161,7 @@ data Term =
| Alts Term [(Term, Term)] -- ^ alternatives by prefix: @pre {t ; s\/c ; ...}@
| Strs [Term] -- ^ conditioning prefix strings: @strs {s ; ...}@
-
+ | Error String -- ^ error values returned by Predef.error
deriving (Show, Eq, Ord)
data Patt =