Hoed-0.5.1: Lightweight algorithmic debugging.

Copyright(c) 2000 Andy Gill (c) 2010 University of Kansas (c) 2013-2018 Maarten Faddegon
LicenseBSD3
Maintainerhoed@maartenfaddegon.nl
Stabilityexperimental
PortabilityPOSIX
Safe HaskellNone
LanguageHaskell2010

Debug.Hoed

Contents

Description

Hoed is a tracer and debugger for the programming language Haskell.

To locate a defect with Hoed you annotate suspected functions and compile as usual. Then you run your program, information about the annotated functions is collected. Finally you connect to a debugging session using a console.

With Hoed you can list and search observed functions applied to argument values and the result values. Hoed also provides algorithmic debugging. An algorithmic debugger finds defects in programs by systematic search. The programmer directs the search by answering a series of yes/no questions about the correctness of specific function applications and their results. Hoed also allows the use of (QuickCheck-style) properties to answer automatically some of the questions arising during algorithmic debugging, and to replace others by simpler questions.

Example usage

Let us consider the following program, a defective implementation of a parity function with a test property.

import Test.QuickCheck

isOdd :: Int -> Bool
isOdd n = isEven (plusOne n)

isEven :: Int -> Bool
isEven n = mod2 n == 0

plusOne :: Int -> Int
plusOne n = n + 1

mod2 :: Int -> Int
mod2 n = div n 2

prop_isOdd :: Int -> Bool
prop_isOdd x = isOdd (2*x+1)

main :: IO ()
main = printO (prop_isOdd 1)

main :: IO ()
main = quickcheck prop_isOdd

Using the property-based test tool QuickCheck we find the counter example `1` for our property.

./MyProgram
*** Failed! Falsifiable (after 1 test): 1

Hoed can help us determine which function is defective. We annotate the functions isOdd, isEven, plusOne and mod2 as follows:

import Debug.Hoed

isOdd :: Int -> Bool
isOdd = observe "isOdd" isOdd'
isOdd' n = isEven (plusOne n)

isEven :: Int -> Bool
isEven = observe "isEven" isEven'
isEven' n = mod2 n == 0

plusOne :: Int -> Int
plusOne = observe "plusOne" plusOne'
plusOne' n = n + 1

mod2 :: Int -> Int
mod2 = observe "mod2" mod2'
mod2' n = div n 2

prop_isOdd :: Int -> Bool
prop_isOdd x = isOdd (2*x+1)

main :: IO ()
main = printO (prop_isOdd 1)

After running the program a computation tree is constructed and the algorithmic debugger is launched in the console.

False

=== program terminated ===
Please wait while the computation tree is constructed...

=== Statistics ===

28 events
4 computation statements
4 nodes + 1 virtual root node in the computation tree
4 edges in computation tree
computation tree has a branch factor of 1.3333333333333333 (i.e the average number of children of non-leaf nodes)

=== Debug Session ===

hdb> adb
======================================================================= [0-0/4]
isOdd 3  = False
? 
right  Judge computation statements right
        according to the intended behaviour/specification of the function.
wrong  Judge computation statements wrong
        according to the intended behaviour/specification of the function.
======================================================================= [0-0/4]
isOdd 3  = False
? wrong
======================================================================= [1-0/4]
isEven 4  = False
? wrong
======================================================================= [2-0/4]
mod2 4  = 2
? wrong
======================================================================= [3-0/4]
Fault located! In:
mod2 4  = 2
hdb>

Read more about Hoed on its project homepage https://wiki.haskell.org/Hoed.

Papers on the theory behind Hoed can be obtained via http://maartenfaddegon.nl/#pub.

I am keen to hear about your experience with Hoed: where did you find it useful and where would you like to see improvement? You can send me an e-mail at hoed@maartenfaddegon.nl, or use the github issue tracker https://github.com/MaartenFaddegon/hoed/issues.

Synopsis

Basic annotations

observe :: Observable a => Text -> a -> a Source #

Functions which you suspect of misbehaving are annotated with observe and should have a cost centre set. The name of the function, the label of the cost centre and the label given to observe need to be the same.

Consider the following function:

triple x = x + x

This function is annotated as follows:

triple y = (observe "triple" (\x -> {# SCC "triple" #}  x + x)) y

To produce computation statements like:

triple 3 = 6

To observe a value its type needs to be of class Observable. We provided instances for many types already. If you have defined your own type, and want to observe a function that takes a value of this type as argument or returns a value of this type, an Observable instance can be derived as follows:

  data MyType = MyNumber Int | MyName String deriving Generic

  instance Observable MyType

runO :: IO a -> IO () Source #

The main entry point; run some IO code, and debug inside it. After the IO action is completed, an algorithmic debugging session is started at http://localhost:10000/ to which you can connect with your webbrowser.

For example:

  main = runO $ do print (triple 3)
                   print (triple 2)

printO :: Show a => a -> IO () Source #

Short for runO . print.

testO :: Show a => (a -> Bool) -> a -> IO () Source #

Repeat and trace a failing testcase

data HoedOptions Source #

Configuration options for running Hoed

Constructors

HoedOptions 

defaultHoedOptions :: HoedOptions Source #

The default is to run silent and pretty print with a width of 110 characters

Property-assisted algorithmic debugging

runOwp :: [Propositions] -> IO a -> IO () Source #

Use property based judging.

printOwp :: Show a => [Propositions] -> a -> IO () Source #

testOwp :: Show a => [Propositions] -> (a -> Bool) -> a -> IO () Source #

Repeat and trace a failing testcase

data PropType Source #

Constructors

Specify 
PropertiesOf 

Instances

data Module Source #

Constructors

Module 

Instances

class ParEq a where Source #

Methods

parEq :: a -> a -> Maybe Bool Source #

parEq :: (Generic a, GParEq (Rep a)) => a -> a -> Maybe Bool Source #

Instances

ParEq Bool Source # 

Methods

parEq :: Bool -> Bool -> Maybe Bool Source #

ParEq Char Source # 

Methods

parEq :: Char -> Char -> Maybe Bool Source #

ParEq Double Source # 

Methods

parEq :: Double -> Double -> Maybe Bool Source #

ParEq Float Source # 

Methods

parEq :: Float -> Float -> Maybe Bool Source #

ParEq Int Source # 

Methods

parEq :: Int -> Int -> Maybe Bool Source #

ParEq Integer Source # 
ParEq a => ParEq [a] Source # 

Methods

parEq :: [a] -> [a] -> Maybe Bool Source #

ParEq a => ParEq (Maybe a) Source # 

Methods

parEq :: Maybe a -> Maybe a -> Maybe Bool Source #

(ParEq a, ParEq b) => ParEq (a, b) Source # 

Methods

parEq :: (a, b) -> (a, b) -> Maybe Bool Source #

(===) :: ParEq a => a -> a -> Bool Source #

runOstore :: String -> IO a -> IO () Source #

Hoed internal function that stores a serialized version of the tree on disk (assisted debugging spawns new instances of Hoed).

conAp :: Observable b => (a -> b) -> b -> a -> b Source #

Build your own debugger with Hoed

runO' :: HoedOptions -> IO a -> IO HoedAnalysis Source #

Entry point giving you access to the internals of Hoed. Also see: runO.

judge :: Trace -> Propositions -> Vertex -> (CompTree -> Int) -> CompTree -> IO Judge Source #

Use propositions to judge a computation statement. First tries restricted and bottom for unevaluated expressions, then unrestricted, and finally with randomly generated values for unevaluated expressions.

unjudgedCharacterCount :: CompTree -> Int Source #

Approximates the complexity of a computation tree by summing the length of the unjudged computation statements (i.e not Right or Wrong) in the tree.

type CompTree = Graph Vertex () Source #

The forest of computation trees. Also see the Libgraph library.

data Vertex Source #

Instances

Eq Vertex Source # 

Methods

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

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

Ord Vertex Source # 
Show Vertex Source # 
Generic Vertex Source # 

Associated Types

type Rep Vertex :: * -> * #

Methods

from :: Vertex -> Rep Vertex x #

to :: Rep Vertex x -> Vertex #

NFData Vertex Source # 

Methods

rnf :: Vertex -> () #

Hashable Vertex Source # 

Methods

hashWithSalt :: Int -> Vertex -> Int #

hash :: Vertex -> Int #

type Rep Vertex Source # 
type Rep Vertex = D1 * (MetaData "Vertex" "Debug.Hoed.CompTree" "Hoed-0.5.1-6GkquCGsp1cHNYyj6cETAl" False) ((:+:) * (C1 * (MetaCons "RootVertex" PrefixI False) (U1 *)) (C1 * (MetaCons "Vertex" PrefixI True) ((:*:) * (S1 * (MetaSel (Just Symbol "vertexStmt") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 * CompStmt)) (S1 * (MetaSel (Just Symbol "vertexJmt") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 * Judgement)))))

data CompStmt Source #

Constructors

CompStmt 

data Judge Source #

Constructors

Judge Judgement

Returns a Judgement (see Libgraph library).

AlternativeTree CompTree Trace

Found counter example with simpler computation tree.

data Verbosity Source #

Constructors

Verbose 
Silent 

API to test Hoed itself

:: FilePath -> IO a -> IO () Source #

Trace and write computation tree to file. Useful for regression testing.

logOwp :: UnevalHandler -> FilePath -> [Propositions] -> IO a -> IO () Source #

As logO, but with property-based judging.

traceOnly :: IO a -> IO () Source #

Only produces a trace. Useful for performance measurements.

The Observable class

class Observable a where Source #

A type class for observable values.

  • For Generic datatypes it can be derived automatically.
  • For opaque datatypes, use observeOpaque or rely on the catch-all ? instance.
  • Custom implementations can exclude one or more fields from the observation:
 instance (Observable a, Observable b) => Observable (excluded, a,b) where
        observe (excluded,a,b) = send "(,,)" (return (,,) excluded << a << b)

Methods

observer :: a -> Parent -> a Source #

observer :: (Generic a, GObservable (Rep a)) => a -> Parent -> a Source #

constrain :: a -> a -> a Source #

constrain :: (Generic a, GConstrain (Rep a)) => a -> a -> a Source #

Instances

Observable Bool Source # 
Observable Char Source # 
Observable Double Source # 
Observable Float Source # 
Observable Int Source # 

Methods

observer :: Int -> Parent -> Int Source #

constrain :: Int -> Int -> Int Source #

Observable Integer Source # 
Observable () Source # 

Methods

observer :: () -> Parent -> () Source #

constrain :: () -> () -> () Source #

Observable Dynamic Source # 
Observable SomeException Source # 
Observable a => Observable [a] Source # 

Methods

observer :: [a] -> Parent -> [a] Source #

constrain :: [a] -> [a] -> [a] Source #

Observable a => Observable (Maybe a) Source # 

Methods

observer :: Maybe a -> Parent -> Maybe a Source #

constrain :: Maybe a -> Maybe a -> Maybe a Source #

Observable a => Observable (IO a) Source # 

Methods

observer :: IO a -> Parent -> IO a Source #

constrain :: IO a -> IO a -> IO a Source #

(Observable a, Observable b) => Observable (a -> b) Source # 

Methods

observer :: (a -> b) -> Parent -> a -> b Source #

constrain :: (a -> b) -> (a -> b) -> a -> b Source #

(Observable a, Observable b) => Observable (Either a b) Source # 

Methods

observer :: Either a b -> Parent -> Either a b Source #

constrain :: Either a b -> Either a b -> Either a b Source #

(Observable a, Observable b) => Observable (a, b) Source # 

Methods

observer :: (a, b) -> Parent -> (a, b) Source #

constrain :: (a, b) -> (a, b) -> (a, b) Source #

(Ix a, Observable a, Observable b) => Observable (Array a b) Source # 

Methods

observer :: Array a b -> Parent -> Array a b Source #

constrain :: Array a b -> Array a b -> Array a b Source #

(Observable a, Observable b, Observable c) => Observable (a, b, c) Source # 

Methods

observer :: (a, b, c) -> Parent -> (a, b, c) Source #

constrain :: (a, b, c) -> (a, b, c) -> (a, b, c) Source #

(Observable a, Observable b, Observable c, Observable d) => Observable (a, b, c, d) Source # 

Methods

observer :: (a, b, c, d) -> Parent -> (a, b, c, d) Source #

constrain :: (a, b, c, d) -> (a, b, c, d) -> (a, b, c, d) Source #

(Observable a, Observable b, Observable c, Observable d, Observable e) => Observable (a, b, c, d, e) Source # 

Methods

observer :: (a, b, c, d, e) -> Parent -> (a, b, c, d, e) Source #

constrain :: (a, b, c, d, e) -> (a, b, c, d, e) -> (a, b, c, d, e) Source #

(<<) :: Observable a => ObserverM (a -> b) -> a -> ObserverM b infixl 9 Source #

thunk :: (a -> Parent -> a) -> a -> ObserverM a Source #

send :: Text -> ObserverM a -> Parent -> a Source #

observeOpaque :: Text -> a -> Parent -> a Source #

observeBase :: Show a => a -> Parent -> a Source #

constrainBase :: (Show a, Eq a) => a -> a -> a Source #

debugO :: IO a -> IO Trace Source #

run some code and return the Trace

data CDS Source #

Instances

Eq CDS Source # 

Methods

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

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

Ord CDS Source # 

Methods

compare :: CDS -> CDS -> Ordering #

(<) :: CDS -> CDS -> Bool #

(<=) :: CDS -> CDS -> Bool #

(>) :: CDS -> CDS -> Bool #

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

max :: CDS -> CDS -> CDS #

min :: CDS -> CDS -> CDS #

Show CDS Source # 

Methods

showsPrec :: Int -> CDS -> ShowS #

show :: CDS -> String #

showList :: [CDS] -> ShowS #

Generic CDS Source # 

Associated Types

type Rep CDS :: * -> * #

Methods

from :: CDS -> Rep CDS x #

to :: Rep CDS x -> CDS #

NFData CDS Source # 

Methods

rnf :: CDS -> () #

type Rep CDS Source # 
type Rep CDS

class Generic a #

Representable types of kind *. This class is derivable in GHC with the DeriveGeneric flag on.

Minimal complete definition

from, to

Instances

Generic Bool 

Associated Types

type Rep Bool :: * -> * #

Methods

from :: Bool -> Rep Bool x #

to :: Rep Bool x -> Bool #

Generic Ordering 

Associated Types

type Rep Ordering :: * -> * #

Methods

from :: Ordering -> Rep Ordering x #

to :: Rep Ordering x -> Ordering #

Generic Exp 

Associated Types

type Rep Exp :: * -> * #

Methods

from :: Exp -> Rep Exp x #

to :: Rep Exp x -> Exp #

Generic Match 

Associated Types

type Rep Match :: * -> * #

Methods

from :: Match -> Rep Match x #

to :: Rep Match x -> Match #

Generic Clause 

Associated Types

type Rep Clause :: * -> * #

Methods

from :: Clause -> Rep Clause x #

to :: Rep Clause x -> Clause #

Generic Pat 

Associated Types

type Rep Pat :: * -> * #

Methods

from :: Pat -> Rep Pat x #

to :: Rep Pat x -> Pat #

Generic Type 

Associated Types

type Rep Type :: * -> * #

Methods

from :: Type -> Rep Type x #

to :: Rep Type x -> Type #

Generic Dec 

Associated Types

type Rep Dec :: * -> * #

Methods

from :: Dec -> Rep Dec x #

to :: Rep Dec x -> Dec #

Generic Name 

Associated Types

type Rep Name :: * -> * #

Methods

from :: Name -> Rep Name x #

to :: Rep Name x -> Name #

Generic FunDep 

Associated Types

type Rep FunDep :: * -> * #

Methods

from :: FunDep -> Rep FunDep x #

to :: Rep FunDep x -> FunDep #

Generic TyVarBndr 

Associated Types

type Rep TyVarBndr :: * -> * #

Generic InjectivityAnn 

Associated Types

type Rep InjectivityAnn :: * -> * #

Generic Overlap 

Associated Types

type Rep Overlap :: * -> * #

Methods

from :: Overlap -> Rep Overlap x #

to :: Rep Overlap x -> Overlap #

Generic DerivStrategy 

Associated Types

type Rep DerivStrategy :: * -> * #

Generic () 

Associated Types

type Rep () :: * -> * #

Methods

from :: () -> Rep () x #

to :: Rep () x -> () #

Generic Version 

Associated Types

type Rep Version :: * -> * #

Methods

from :: Version -> Rep Version x #

to :: Rep Version x -> Version #

Generic Void 

Associated Types

type Rep Void :: * -> * #

Methods

from :: Void -> Rep Void x #

to :: Rep Void x -> Void #

Generic ExitCode 

Associated Types

type Rep ExitCode :: * -> * #

Methods

from :: ExitCode -> Rep ExitCode x #

to :: Rep ExitCode x -> ExitCode #

Generic All 

Associated Types

type Rep All :: * -> * #

Methods

from :: All -> Rep All x #

to :: Rep All x -> All #

Generic Any 

Associated Types

type Rep Any :: * -> * #

Methods

from :: Any -> Rep Any x #

to :: Rep Any x -> Any #

Generic Fixity 

Associated Types

type Rep Fixity :: * -> * #

Methods

from :: Fixity -> Rep Fixity x #

to :: Rep Fixity x -> Fixity #

Generic Associativity 

Associated Types

type Rep Associativity :: * -> * #

Generic SourceUnpackedness 
Generic SourceStrictness 
Generic DecidedStrictness 
Generic Clock 

Associated Types

type Rep Clock :: * -> * #

Methods

from :: Clock -> Rep Clock x #

to :: Rep Clock x -> Clock #

Generic TimeSpec 

Associated Types

type Rep TimeSpec :: * -> * #

Methods

from :: TimeSpec -> Rep TimeSpec x #

to :: Rep TimeSpec x -> TimeSpec #

Generic Extension 

Associated Types

type Rep Extension :: * -> * #

Generic ForeignSrcLang 

Associated Types

type Rep ForeignSrcLang :: * -> * #

Generic AssistedMessage 
Generic Judgement 

Associated Types

type Rep Judgement :: * -> * #

Generic Doc 

Associated Types

type Rep Doc :: * -> * #

Methods

from :: Doc -> Rep Doc x #

to :: Rep Doc x -> Doc #

Generic TextDetails 

Associated Types

type Rep TextDetails :: * -> * #

Generic Style 

Associated Types

type Rep Style :: * -> * #

Methods

from :: Style -> Rep Style x #

to :: Rep Style x -> Style #

Generic Mode 

Associated Types

type Rep Mode :: * -> * #

Methods

from :: Mode -> Rep Mode x #

to :: Rep Mode x -> Mode #

Generic ModName 

Associated Types

type Rep ModName :: * -> * #

Methods

from :: ModName -> Rep ModName x #

to :: Rep ModName x -> ModName #

Generic PkgName 

Associated Types

type Rep PkgName :: * -> * #

Methods

from :: PkgName -> Rep PkgName x #

to :: Rep PkgName x -> PkgName #

Generic Module 

Associated Types

type Rep Module :: * -> * #

Methods

from :: Module -> Rep Module x #

to :: Rep Module x -> Module #

Generic OccName 

Associated Types

type Rep OccName :: * -> * #

Methods

from :: OccName -> Rep OccName x #

to :: Rep OccName x -> OccName #

Generic NameFlavour 

Associated Types

type Rep NameFlavour :: * -> * #

Generic NameSpace 

Associated Types

type Rep NameSpace :: * -> * #

Generic Loc 

Associated Types

type Rep Loc :: * -> * #

Methods

from :: Loc -> Rep Loc x #

to :: Rep Loc x -> Loc #

Generic Info 

Associated Types

type Rep Info :: * -> * #

Methods

from :: Info -> Rep Info x #

to :: Rep Info x -> Info #

Generic ModuleInfo 

Associated Types

type Rep ModuleInfo :: * -> * #

Generic Fixity 

Associated Types

type Rep Fixity :: * -> * #

Methods

from :: Fixity -> Rep Fixity x #

to :: Rep Fixity x -> Fixity #

Generic FixityDirection 
Generic Lit 

Associated Types

type Rep Lit :: * -> * #

Methods

from :: Lit -> Rep Lit x #

to :: Rep Lit x -> Lit #

Generic Body 

Associated Types

type Rep Body :: * -> * #

Methods

from :: Body -> Rep Body x #

to :: Rep Body x -> Body #

Generic Guard 

Associated Types

type Rep Guard :: * -> * #

Methods

from :: Guard -> Rep Guard x #

to :: Rep Guard x -> Guard #

Generic Stmt 

Associated Types

type Rep Stmt :: * -> * #

Methods

from :: Stmt -> Rep Stmt x #

to :: Rep Stmt x -> Stmt #

Generic Range 

Associated Types

type Rep Range :: * -> * #

Methods

from :: Range -> Rep Range x #

to :: Rep Range x -> Range #

Generic DerivClause 

Associated Types

type Rep DerivClause :: * -> * #

Generic TypeFamilyHead 

Associated Types

type Rep TypeFamilyHead :: * -> * #

Generic TySynEqn 

Associated Types

type Rep TySynEqn :: * -> * #

Methods

from :: TySynEqn -> Rep TySynEqn x #

to :: Rep TySynEqn x -> TySynEqn #

Generic FamFlavour 

Associated Types

type Rep FamFlavour :: * -> * #

Generic Foreign 

Associated Types

type Rep Foreign :: * -> * #

Methods

from :: Foreign -> Rep Foreign x #

to :: Rep Foreign x -> Foreign #

Generic Callconv 

Associated Types

type Rep Callconv :: * -> * #

Methods

from :: Callconv -> Rep Callconv x #

to :: Rep Callconv x -> Callconv #

Generic Safety 

Associated Types

type Rep Safety :: * -> * #

Methods

from :: Safety -> Rep Safety x #

to :: Rep Safety x -> Safety #

Generic Pragma 

Associated Types

type Rep Pragma :: * -> * #

Methods

from :: Pragma -> Rep Pragma x #

to :: Rep Pragma x -> Pragma #

Generic Inline 

Associated Types

type Rep Inline :: * -> * #

Methods

from :: Inline -> Rep Inline x #

to :: Rep Inline x -> Inline #

Generic RuleMatch 

Associated Types

type Rep RuleMatch :: * -> * #

Generic Phases 

Associated Types

type Rep Phases :: * -> * #

Methods

from :: Phases -> Rep Phases x #

to :: Rep Phases x -> Phases #

Generic RuleBndr 

Associated Types

type Rep RuleBndr :: * -> * #

Methods

from :: RuleBndr -> Rep RuleBndr x #

to :: Rep RuleBndr x -> RuleBndr #

Generic AnnTarget 

Associated Types

type Rep AnnTarget :: * -> * #

Generic SourceUnpackedness 
Generic SourceStrictness 
Generic DecidedStrictness 
Generic Con 

Associated Types

type Rep Con :: * -> * #

Methods

from :: Con -> Rep Con x #

to :: Rep Con x -> Con #

Generic Bang 

Associated Types

type Rep Bang :: * -> * #

Methods

from :: Bang -> Rep Bang x #

to :: Rep Bang x -> Bang #

Generic PatSynDir 

Associated Types

type Rep PatSynDir :: * -> * #

Generic PatSynArgs 

Associated Types

type Rep PatSynArgs :: * -> * #

Generic FamilyResultSig 
Generic TyLit 

Associated Types

type Rep TyLit :: * -> * #

Methods

from :: TyLit -> Rep TyLit x #

to :: Rep TyLit x -> TyLit #

Generic Role 

Associated Types

type Rep Role :: * -> * #

Methods

from :: Role -> Rep Role x #

to :: Rep Role x -> Role #

Generic AnnLookup 

Associated Types

type Rep AnnLookup :: * -> * #

Generic Parent # 

Associated Types

type Rep Parent :: * -> * #

Methods

from :: Parent -> Rep Parent x #

to :: Rep Parent x -> Parent #

Generic Change # 

Associated Types

type Rep Change :: * -> * #

Methods

from :: Change -> Rep Change x #

to :: Rep Change x -> Change #

Generic Event # 

Associated Types

type Rep Event :: * -> * #

Methods

from :: Event -> Rep Event x #

to :: Rep Event x -> Event #

Generic CDS # 

Associated Types

type Rep CDS :: * -> * #

Methods

from :: CDS -> Rep CDS x #

to :: Rep CDS x -> CDS #

Generic StmtDetails # 

Associated Types

type Rep StmtDetails :: * -> * #

Generic CompStmt # 

Associated Types

type Rep CompStmt :: * -> * #

Methods

from :: CompStmt -> Rep CompStmt x #

to :: Rep CompStmt x -> CompStmt #

Generic Vertex # 

Associated Types

type Rep Vertex :: * -> * #

Methods

from :: Vertex -> Rep Vertex x #

to :: Rep Vertex x -> Vertex #

Generic [a] 

Associated Types

type Rep [a] :: * -> * #

Methods

from :: [a] -> Rep [a] x #

to :: Rep [a] x -> [a] #

Generic (Maybe a) 

Associated Types

type Rep (Maybe a) :: * -> * #

Methods

from :: Maybe a -> Rep (Maybe a) x #

to :: Rep (Maybe a) x -> Maybe a #

Generic (Par1 p) 

Associated Types

type Rep (Par1 p) :: * -> * #

Methods

from :: Par1 p -> Rep (Par1 p) x #

to :: Rep (Par1 p) x -> Par1 p #

Generic (Complex a) 

Associated Types

type Rep (Complex a) :: * -> * #

Methods

from :: Complex a -> Rep (Complex a) x #

to :: Rep (Complex a) x -> Complex a #

Generic (Min a) 

Associated Types

type Rep (Min a) :: * -> * #

Methods

from :: Min a -> Rep (Min a) x #

to :: Rep (Min a) x -> Min a #

Generic (Max a) 

Associated Types

type Rep (Max a) :: * -> * #

Methods

from :: Max a -> Rep (Max a) x #

to :: Rep (Max a) x -> Max a #

Generic (First a) 

Associated Types

type Rep (First a) :: * -> * #

Methods

from :: First a -> Rep (First a) x #

to :: Rep (First a) x -> First a #

Generic (Last a) 

Associated Types

type Rep (Last a) :: * -> * #

Methods

from :: Last a -> Rep (Last a) x #

to :: Rep (Last a) x -> Last a #

Generic (WrappedMonoid m) 

Associated Types

type Rep (WrappedMonoid m) :: * -> * #

Generic (Option a) 

Associated Types

type Rep (Option a) :: * -> * #

Methods

from :: Option a -> Rep (Option a) x #

to :: Rep (Option a) x -> Option a #

Generic (NonEmpty a) 

Associated Types

type Rep (NonEmpty a) :: * -> * #

Methods

from :: NonEmpty a -> Rep (NonEmpty a) x #

to :: Rep (NonEmpty a) x -> NonEmpty a #

Generic (ZipList a) 

Associated Types

type Rep (ZipList a) :: * -> * #

Methods

from :: ZipList a -> Rep (ZipList a) x #

to :: Rep (ZipList a) x -> ZipList a #

Generic (Identity a) 

Associated Types

type Rep (Identity a) :: * -> * #

Methods

from :: Identity a -> Rep (Identity a) x #

to :: Rep (Identity a) x -> Identity a #

Generic (Dual a) 

Associated Types

type Rep (Dual a) :: * -> * #

Methods

from :: Dual a -> Rep (Dual a) x #

to :: Rep (Dual a) x -> Dual a #

Generic (Endo a) 

Associated Types

type Rep (Endo a) :: * -> * #

Methods

from :: Endo a -> Rep (Endo a) x #

to :: Rep (Endo a) x -> Endo a #

Generic (Sum a) 

Associated Types

type Rep (Sum a) :: * -> * #

Methods

from :: Sum a -> Rep (Sum a) x #

to :: Rep (Sum a) x -> Sum a #

Generic (Product a) 

Associated Types

type Rep (Product a) :: * -> * #

Methods

from :: Product a -> Rep (Product a) x #

to :: Rep (Product a) x -> Product a #

Generic (First a) 

Associated Types

type Rep (First a) :: * -> * #

Methods

from :: First a -> Rep (First a) x #

to :: Rep (First a) x -> First a #

Generic (Last a) 

Associated Types

type Rep (Last a) :: * -> * #

Methods

from :: Last a -> Rep (Last a) x #

to :: Rep (Last a) x -> Last a #

Generic (Tree a) 

Associated Types

type Rep (Tree a) :: * -> * #

Methods

from :: Tree a -> Rep (Tree a) x #

to :: Rep (Tree a) x -> Tree a #

Generic (ViewL a) 

Associated Types

type Rep (ViewL a) :: * -> * #

Methods

from :: ViewL a -> Rep (ViewL a) x #

to :: Rep (ViewL a) x -> ViewL a #

Generic (ViewR a) 

Associated Types

type Rep (ViewR a) :: * -> * #

Methods

from :: ViewR a -> Rep (ViewR a) x #

to :: Rep (ViewR a) x -> ViewR a #

Generic (Doc a) 

Associated Types

type Rep (Doc a) :: * -> * #

Methods

from :: Doc a -> Rep (Doc a) x #

to :: Rep (Doc a) x -> Doc a #

Generic (Window a) 

Associated Types

type Rep (Window a) :: * -> * #

Methods

from :: Window a -> Rep (Window a) x #

to :: Rep (Window a) x -> Window a #

Generic (Either a b) 

Associated Types

type Rep (Either a b) :: * -> * #

Methods

from :: Either a b -> Rep (Either a b) x #

to :: Rep (Either a b) x -> Either a b #

Generic (V1 k p) 

Associated Types

type Rep (V1 k p) :: * -> * #

Methods

from :: V1 k p -> Rep (V1 k p) x #

to :: Rep (V1 k p) x -> V1 k p #

Generic (U1 k p) 

Associated Types

type Rep (U1 k p) :: * -> * #

Methods

from :: U1 k p -> Rep (U1 k p) x #

to :: Rep (U1 k p) x -> U1 k p #

Generic (a, b) 

Associated Types

type Rep (a, b) :: * -> * #

Methods

from :: (a, b) -> Rep (a, b) x #

to :: Rep (a, b) x -> (a, b) #

Generic (Arg a b) 

Associated Types

type Rep (Arg a b) :: * -> * #

Methods

from :: Arg a b -> Rep (Arg a b) x #

to :: Rep (Arg a b) x -> Arg a b #

Generic (WrappedMonad m a) 

Associated Types

type Rep (WrappedMonad m a) :: * -> * #

Methods

from :: WrappedMonad m a -> Rep (WrappedMonad m a) x #

to :: Rep (WrappedMonad m a) x -> WrappedMonad m a #

Generic (Proxy k t) 

Associated Types

type Rep (Proxy k t) :: * -> * #

Methods

from :: Proxy k t -> Rep (Proxy k t) x #

to :: Rep (Proxy k t) x -> Proxy k t #

Generic (Arc vertex arc) 

Associated Types

type Rep (Arc vertex arc) :: * -> * #

Methods

from :: Arc vertex arc -> Rep (Arc vertex arc) x #

to :: Rep (Arc vertex arc) x -> Arc vertex arc #

Generic (Graph vertex arc) 

Associated Types

type Rep (Graph vertex arc) :: * -> * #

Methods

from :: Graph vertex arc -> Rep (Graph vertex arc) x #

to :: Rep (Graph vertex arc) x -> Graph vertex arc #

Generic (Rec1 k f p) 

Associated Types

type Rep (Rec1 k f p) :: * -> * #

Methods

from :: Rec1 k f p -> Rep (Rec1 k f p) x #

to :: Rep (Rec1 k f p) x -> Rec1 k f p #

Generic (URec k (Ptr ()) p) 

Associated Types

type Rep (URec k (Ptr ()) p) :: * -> * #

Methods

from :: URec k (Ptr ()) p -> Rep (URec k (Ptr ()) p) x #

to :: Rep (URec k (Ptr ()) p) x -> URec k (Ptr ()) p #

Generic (URec k Char p) 

Associated Types

type Rep (URec k Char p) :: * -> * #

Methods

from :: URec k Char p -> Rep (URec k Char p) x #

to :: Rep (URec k Char p) x -> URec k Char p #

Generic (URec k Double p) 

Associated Types

type Rep (URec k Double p) :: * -> * #

Methods

from :: URec k Double p -> Rep (URec k Double p) x #

to :: Rep (URec k Double p) x -> URec k Double p #

Generic (URec k Float p) 

Associated Types

type Rep (URec k Float p) :: * -> * #

Methods

from :: URec k Float p -> Rep (URec k Float p) x #

to :: Rep (URec k Float p) x -> URec k Float p #

Generic (URec k Int p) 

Associated Types

type Rep (URec k Int p) :: * -> * #

Methods

from :: URec k Int p -> Rep (URec k Int p) x #

to :: Rep (URec k Int p) x -> URec k Int p #

Generic (URec k Word p) 

Associated Types

type Rep (URec k Word p) :: * -> * #

Methods

from :: URec k Word p -> Rep (URec k Word p) x #

to :: Rep (URec k Word p) x -> URec k Word p #

Generic (a, b, c) 

Associated Types

type Rep (a, b, c) :: * -> * #

Methods

from :: (a, b, c) -> Rep (a, b, c) x #

to :: Rep (a, b, c) x -> (a, b, c) #

Generic (WrappedArrow a b c) 

Associated Types

type Rep (WrappedArrow a b c) :: * -> * #

Methods

from :: WrappedArrow a b c -> Rep (WrappedArrow a b c) x #

to :: Rep (WrappedArrow a b c) x -> WrappedArrow a b c #

Generic (Const k a b) 

Associated Types

type Rep (Const k a b) :: * -> * #

Methods

from :: Const k a b -> Rep (Const k a b) x #

to :: Rep (Const k a b) x -> Const k a b #

Generic (Alt k f a) 

Associated Types

type Rep (Alt k f a) :: * -> * #

Methods

from :: Alt k f a -> Rep (Alt k f a) x #

to :: Rep (Alt k f a) x -> Alt k f a #

Generic (K1 k i c p) 

Associated Types

type Rep (K1 k i c p) :: * -> * #

Methods

from :: K1 k i c p -> Rep (K1 k i c p) x #

to :: Rep (K1 k i c p) x -> K1 k i c p #

Generic ((:+:) k f g p) 

Associated Types

type Rep ((k :+: f) g p) :: * -> * #

Methods

from :: (k :+: f) g p -> Rep ((k :+: f) g p) x #

to :: Rep ((k :+: f) g p) x -> (k :+: f) g p #

Generic ((:*:) k f g p) 

Associated Types

type Rep ((k :*: f) g p) :: * -> * #

Methods

from :: (k :*: f) g p -> Rep ((k :*: f) g p) x #

to :: Rep ((k :*: f) g p) x -> (k :*: f) g p #

Generic (a, b, c, d) 

Associated Types

type Rep (a, b, c, d) :: * -> * #

Methods

from :: (a, b, c, d) -> Rep (a, b, c, d) x #

to :: Rep (a, b, c, d) x -> (a, b, c, d) #

Generic (Product k f g a) 

Associated Types

type Rep (Product k f g a) :: * -> * #

Methods

from :: Product k f g a -> Rep (Product k f g a) x #

to :: Rep (Product k f g a) x -> Product k f g a #

Generic (Sum k f g a) 

Associated Types

type Rep (Sum k f g a) :: * -> * #

Methods

from :: Sum k f g a -> Rep (Sum k f g a) x #

to :: Rep (Sum k f g a) x -> Sum k f g a #

Generic (M1 k i c f p) 

Associated Types

type Rep (M1 k i c f p) :: * -> * #

Methods

from :: M1 k i c f p -> Rep (M1 k i c f p) x #

to :: Rep (M1 k i c f p) x -> M1 k i c f p #

Generic ((:.:) k2 k1 f g p) 

Associated Types

type Rep ((k2 :.: k1) f g p) :: * -> * #

Methods

from :: (k2 :.: k1) f g p -> Rep ((k2 :.: k1) f g p) x #

to :: Rep ((k2 :.: k1) f g p) x -> (k2 :.: k1) f g p #

Generic (a, b, c, d, e) 

Associated Types

type Rep (a, b, c, d, e) :: * -> * #

Methods

from :: (a, b, c, d, e) -> Rep (a, b, c, d, e) x #

to :: Rep (a, b, c, d, e) x -> (a, b, c, d, e) #

Generic (Compose k1 k2 f g a) 

Associated Types

type Rep (Compose k1 k2 f g a) :: * -> * #

Methods

from :: Compose k1 k2 f g a -> Rep (Compose k1 k2 f g a) x #

to :: Rep (Compose k1 k2 f g a) x -> Compose k1 k2 f g a #

Generic (a, b, c, d, e, f) 

Associated Types

type Rep (a, b, c, d, e, f) :: * -> * #

Methods

from :: (a, b, c, d, e, f) -> Rep (a, b, c, d, e, f) x #

to :: Rep (a, b, c, d, e, f) x -> (a, b, c, d, e, f) #

Generic (a, b, c, d, e, f, g) 

Associated Types

type Rep (a, b, c, d, e, f, g) :: * -> * #

Methods

from :: (a, b, c, d, e, f, g) -> Rep (a, b, c, d, e, f, g) x #

to :: Rep (a, b, c, d, e, f, g) x -> (a, b, c, d, e, f, g) #

Orphan instances

Observable a Source #

A catch-all instance for non observable types that produces the opaque observation ?.

Methods

observer :: a -> Parent -> a Source #

constrain :: a -> a -> a Source #