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
import QuickCheck | |
import Providers | |
%language TypeProviders | |
prop_RevRev : Eq a => List a -> Bool | |
prop_RevRev xs = reverse (reverse xs) == xs | |
stupid : List a -> List a |
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
module Main | |
import System.Random.TF.Gen | |
genNums : Int -> TFGen -> IO TFGen | |
genNums i gen = if i > 0 then | |
let (n, gen') = tfGenNext gen in | |
do putStrLn (show i ++"\t0x"++show n) | |
genNums (i-1) (fst (split gen')) | |
else return gen |
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
module SExpParse | |
import Lightyear.Core | |
import Lightyear.Combinators | |
import Lightyear.Strings | |
%default total | |
data MessageFmt = KWD String | |
| STRING |
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
module Test | |
import Provider | |
import Database | |
import Queries | |
%language TypeProviders | |
%link C "sqlite3api.o" |
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
%reflection | |
solveHasTable : Type -> Tactic | |
solveHasTable (HasTable (_::tl) name s) = | |
Try (Refine "Here" `Seq` Solve) | |
(Refine "There" `Seq` (Solve `Seq` solveHasTable (HasTable tl name s))) | |
solveHasTable (HasTable (a++b) _ _) = Refine "Here" `Seq` Solve | |
solveHasTable (HasTable _ name s) = Refine "Here" `Seq` Solve |
NewerOlder