X-Git-Url: http://git.megacz.com/?p=coq-hetmet.git;a=blobdiff_plain;f=examples%2FDemo.hs;h=f5069fab2b6648522c485de6255842759629f0c5;hp=74bbef0ef54ecdd731b6f8e0e1384ebeaae86e33;hb=bb5ad91dc2d9cf1e35895e293b4e3e1478b4af00;hpb=15df3430938d7175361b848de6578aea195e612f diff --git a/examples/Demo.hs b/examples/Demo.hs index 74bbef0..f5069fa 100644 --- a/examples/Demo.hs +++ b/examples/Demo.hs @@ -4,7 +4,14 @@ import GHC.HetMet.CodeTypes import GHC.HetMet.Private import GArrowTikZ -foo x = <[ ~~x ]> -foo' = unG . pga_flatten . foo . pga_unflatten ---foo x z = <[ let y = ~~x in ~~z y y ]> -main = tikz (foo' (PGArrowD { unG = TikZ_const 12 })) +{- +foo :: (forall g a . <[ () -> a + PGArrow g (GArrowUnit g) a -> + (forall b . PGArrow g (GArrowTensor g b b) b) -> +-} +--foo con mer = <[ ~~mer ~~con ~~con ]> +foo f = <[ ~~f ]> + +--tester2 f = <[ \x -> ~~f x x ]> + +main = tikz' $ \a b -> pga_flatten (foo (pga_unflatten a))