brainfuck-tut-0.7.0.2: A simple BF interpreter.

Copyright(c) Allele Dev 2014
LicenseBSD-3
Maintainerallele.dev@gmail.com
Stabilityexperimental
PortabilityPOSIX
Safe HaskellSafe
LanguageHaskell2010

Language.Brainfuck.Types

Description

 

Synopsis

Documentation

type Tape = Array Int Word8 Source #

Tape is an alias for the interpreter storage type

type DataPointer = Int Source #

DataPointer is an alias for the memory pointer

newtype ProgramCounter Source #

ProgramCounter is a nominal type to track the current instruction while distinguishing it from DataPointer

Constructors

PC Int 

data Term Source #

Term represents the abstract syntax for the BF language

Instances

Eq Term Source # 

Methods

(==) :: Term -> Term -> Bool #

(/=) :: Term -> Term -> Bool #

Show Term Source # 

Methods

showsPrec :: Int -> Term -> ShowS #

show :: Term -> String #

showList :: [Term] -> ShowS #

data Direction Source #

Direction is used to track which direction we're jumping in

Constructors

Forward 
Backward 

Instances