Add example terms for testing

This commit is contained in:
Joscha 2020-12-13 19:01:37 +00:00
parent 655fe97cbc
commit 52310c766f
2 changed files with 20 additions and 0 deletions

View file

@ -0,0 +1,19 @@
{-# LANGUAGE OverloadedStrings #-}
module Propa.Prolog.Example where
import qualified Data.Text as T
import Propa.Prolog.Types
db :: Db T.Text
db =
[ Def "append" [Stat "nil" [], Var "Y", Var "Y"] []
, Def "append" [Stat "cons" [Var "X", Var "XS"], Var "Y", Stat "cons" [Var "X", Var "Z"]] [Stat "append" [Var "XS", Var "Y", Var "Z"]]
]
l12 :: Term T.Text
l12 = Stat "cons" [Stat "1" [], Stat "cons" [Stat "2" [], Stat "nil" []]]
l345 :: Term T.Text
l345 = Stat "cons" [Stat "3" [], Stat "cons" [Stat "4" [], Stat "cons" [Stat "5" [], Stat "nil" []]]]