From e8aa32d746df7b8554eda1bde0ca1fc513f07b58 Mon Sep 17 00:00:00 2001 From: aarne Date: Fri, 3 Jun 2005 20:51:58 +0000 Subject: example substitutions --- src/GF/UseGrammar/GetTree.hs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/GF/UseGrammar/GetTree.hs') 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 -- cgit v1.2.3