summaryrefslogtreecommitdiff
path: root/src/GF/UseGrammar
diff options
context:
space:
mode:
Diffstat (limited to 'src/GF/UseGrammar')
-rw-r--r--src/GF/UseGrammar/GetTree.hs7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/GF/UseGrammar/GetTree.hs b/src/GF/UseGrammar/GetTree.hs
index a8d5fcab2..e71475654 100644
--- a/src/GF/UseGrammar/GetTree.hs
+++ b/src/GF/UseGrammar/GetTree.hs
@@ -5,9 +5,9 @@
-- Stability : (stable)
-- Portability : (portable)
--
--- > CVS $Date: 2005/04/21 16:23:47 $
--- > CVS $Author: bringert $
--- > CVS $Revision: 1.7 $
+-- > CVS $Date: 2005/06/03 21:51:59 $
+-- > CVS $Author: aarne $
+-- > CVS $Revision: 1.8 $
--
-- how to form linearizable trees from strings and from terms of different levels
--
@@ -39,6 +39,7 @@ string2tree :: StateGrammar -> String -> Tree
string2tree gr = errVal uTree . string2treeErr gr
string2treeErr :: StateGrammar -> String -> Err Tree
+string2treeErr _ "" = Bad "empty string"
string2treeErr gr s = do
t <- pTerm s
let t1 = refreshMetas [] t