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 SOP where | |
import Control.Applicative | |
import Data.Function | |
import Data.List | |
import Data.Maybe | |
import Data.Either | |
import Debug.Trace | |
data Expr |
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
interface addOne_i; | |
task automatic run (input integer a, output integer b); | |
b = a + 1; | |
endtask | |
endinterface | |
interface map_i #( parameter N=32, parameter type ELEMTYPE=logic ) | |
( interface f ); | |
task automatic run ( input ELEMTYPE arg [N-1:0] | |
, output ELEMTYPE res [N-1:0]); |
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 DeriveFunctor, DeriveFoldable, DeriveTraversable, | |
ScopedTypeVariables, OverloadedStrings, TypeSynonymInstances, | |
FlexibleInstances, GADTs #-} | |
module Core where | |
import Bound | |
import Bound.Name | |
import Bound.Var | |
import Control.Applicative | |
import Control.Comonad |
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
-- http://www.andres-loeh.de/LambdaPi/ | |
module LambaPi where | |
data TermI | |
= Ann TermC TermC | |
| Star | |
| Pi TermC TermC | |
| Bound Int | |
| Free Name | |
| TermI :@: TermC |
This file has been truncated, but you can view the full file.
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
*Signal> fails | |
Just 2 :: | |
Nothing :: | |
take 1 | |
(Stream instance of Prelude.Functor.Functor, method map snd | |
(zipWith apply | |
(zipWith apply | |
(calc :: | |
Delay (repeat calc)) | |
(map fst |
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 DeriveFoldable, DeriveFunctor, DeriveTraversable #-} | |
module SimpleCore where | |
import Bound | |
import Bound.Name | |
import Bound.Var | |
import Control.Applicative | |
import Control.Comonad | |
import Control.Monad | |
import Data.Bifunctor |
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
/opt/ghc/7.8.3$ make | |
cd ./src/ghc-7.8.3 && ./configure --prefix=/opt/ghc/7.8.3 && make install | |
checking for path to top of build tree... /opt/ghc/7.8.3/src/ghc-7.8.3 | |
Build platform inferred as: x86_64-apple-darwin | |
Host platform inferred as: x86_64-apple-darwin | |
Target platform inferred as: x86_64-apple-darwin | |
GHC build : x86_64-apple-darwin | |
GHC host : x86_64-apple-darwin | |
GHC target : x86_64-apple-darwin | |
checking for perl... /usr/bin/perl |
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 DeriveFunctor, DeriveFoldable, DeriveTraversable, | |
ScopedTypeVariables #-} | |
{- | | |
Usage: | |
>>> inferType1 (const undefined) dollar | |
>>> inferType2 (const undefined) dollar | |
>>> inferType3 (const undefined) dollar | |
>>> inferType4 (const undefined) id dollar | |
-} | |
module DepLamInfer where |
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 DeriveFunctor, DeriveFoldable, DeriveTraversable #-} | |
{-# OPTIONS_GHC -fno-full-laziness #-} | |
module Main where | |
import Bound | |
import Bound.Name | |
import Bound.Var | |
import Control.Applicative | |
import Control.Comonad | |
import Control.Monad |
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 CLaSH.Signal.Enabled.SCase where | |
import Data.Default | |
import Language.Haskell.TH | |
scase e = do | |
e' <- e | |
case e' of | |
CaseE e2 ms -> do | |
nm1 <- newName "eb" |