From 6719aedde34c3a4f0ccb78931968c6fe490b3282 Mon Sep 17 00:00:00 2001 From: aarne Date: Fri, 26 Mar 2004 20:08:30 +0000 Subject: Better help. --- src/GF/Grammar/Macros.hs | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'src/GF/Grammar') diff --git a/src/GF/Grammar/Macros.hs b/src/GF/Grammar/Macros.hs index cc43377cb..075da2a9d 100644 --- a/src/GF/Grammar/Macros.hs +++ b/src/GF/Grammar/Macros.hs @@ -128,6 +128,20 @@ unComputed t = case t of Computed v -> unComputed v _ -> t --- composSafeOp unComputed t + +{- +--- defined (better) in compile/PrOld + +stripTerm :: Term -> Term +stripTerm t = case t of + Q _ c -> Cn c + QC _ c -> Cn c + T ti psts -> T ti [(stripPatt p, stripTerm v) | (p,v) <- psts] + _ -> composSafeOp stripTerm t + where + stripPatt p = errVal p $ term2patt $ stripTerm $ patt2term p +-} + computed = Computed termForm :: Term -> Err ([(Ident)], Term, [Term]) -- cgit v1.2.3