This file contains hidden or 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
#include <linux/cdev.h> | |
#include <linux/device.h> | |
#include <linux/fs.h> | |
#include <linux/gpio.h> | |
#include <linux/module.h> | |
#include <linux/sched.h> | |
#include <linux/version.h> | |
#include <asm/uaccess.h> |
This file contains hidden or 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 GeneralizedNewtypeDeriving #-} | |
module PipeLog where | |
import Control.Applicative | |
import Data.Functor.Identity | |
import Pipes | |
import qualified Pipes.Prelude as P | |
newtype LogT l m a = |
This file contains hidden or 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 GADTs #-} | |
-- | Toy instructional example of GADTs: simple dynamic types. | |
-- | |
-- Before tackling this, skim the GHC docs section on GADTs: | |
-- | |
-- <http://www.haskell.org/ghc/docs/latest/html/users_guide/data-type-extensions.html#gadt> | |
-- | |
-- As you read this example keep in mind this quote from the | |
-- docs: "The key point about GADTs is that /pattern matching |
This file contains hidden or 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
#! /usr/bin/env bash | |
# Target and build configuration. | |
TARGET=arm-none-eabi | |
PREFIX=/opt/arm-none-eabi-4.7.1 | |
# Sources to build from. | |
BINUTILS=binutils-2.23.1 | |
GCC=gcc-4.7.1 | |
NEWLIB=newlib-1.20.0 |
This file contains hidden or 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
;; outlet code for implementing traditional macro expansion | |
;; macros | |
(define (expand form) | |
(cond | |
((variable? form) form) | |
((literal? form) form) | |
((macro? (car form)) | |
(expand ((macro-function (car form)) form))) |
NewerOlder