summaryrefslogtreecommitdiff
path: root/examples/gadt-transfer/VeryFoods.hs
diff options
context:
space:
mode:
authorjohn.j.camilleri <john.j.camilleri@chalmers.se>2013-09-16 07:17:27 +0000
committerjohn.j.camilleri <john.j.camilleri@chalmers.se>2013-09-16 07:17:27 +0000
commitf5461eb3d4eb2605b546a4ed202c12bcdaa1f4e4 (patch)
tree946c9e8542b8e8271b6b529a95c0400fa6613cb4 /examples/gadt-transfer/VeryFoods.hs
parent8e1c6cca407c82fc09569d80c231b8d256735989 (diff)
Remove contribs and examples
Everything has now been moved to a separate repository at https://github.com/GrammaticalFramework/gf-contrib The contents of the examples folder are build during SetupWeb
Diffstat (limited to 'examples/gadt-transfer/VeryFoods.hs')
-rw-r--r--examples/gadt-transfer/VeryFoods.hs23
1 files changed, 0 insertions, 23 deletions
diff --git a/examples/gadt-transfer/VeryFoods.hs b/examples/gadt-transfer/VeryFoods.hs
deleted file mode 100644
index ad6b6dc7f..000000000
--- a/examples/gadt-transfer/VeryFoods.hs
+++ /dev/null
@@ -1,23 +0,0 @@
-{-# OPTIONS_GHC -fglasgow-exts #-}
-module Main where
-
-import PGF
-import Foods
-
--- example of using GADT: turn every occurrence of "boring" to "very boring"
-
-main = do
- pgf <- readPGF "Foods.pgf"
- interact (doVery pgf)
-
-doVery pgf s = case parseAllLang pgf (startCat pgf) s of
- (l,t:_):_ -> unlines $ return $ linearize pgf l $ gf $ veryC $ fg t
-
-veryC :: GComment -> GComment
-veryC = very
-
-very :: forall a. Foods.Tree a -> Foods.Tree a
-very t = case t of
- GBoring -> GVery GBoring
- _ -> composOp very t
-