View church-encoding.hs
{-# LANGUAGE RankNTypes #-} | |
newtype BST k v = Roll | |
{ unroll :: forall r. r -> (k -> v -> r -> r -> r) -> r | |
} | |
-- Two constructors | |
leave :: BST k v | |
leave = Roll const |
View sml.el
(defun isml () | |
"If sml repl exists, then restart it else create a new repl." | |
(interactive) | |
(when (get-buffer "*sml*") | |
(with-current-buffer "*sml*" | |
(when (process-live-p "sml") | |
(comint-send-eof))) | |
(sleep-for 0.2)) | |
(sml-run "sml" "")) |