This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- a djinn environment that encodes an instance of the | |
-- post correspondence problem. it requires recursive data | |
-- types. | |
data Foo a b x y = Foo (Bar a b (a x) (b (a (a y)))) | |
(Bar a b (a (b x)) (a (a y))) | |
(Bar a b (b (b (a x))) (b (b y))) | |
-- we need duplicate to enforce N>=1 | |
data Bar a b x y = Bar (Bar a b (a x) (b (a (a y)))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE Arrows, TemplateHaskell #-} | |
module Main where | |
import Prelude hiding (id, init, (.)) | |
import Control.Arrow | |
import Control.Category |
NewerOlder