nano-js-0.1.0.0: Small Language for Implementing Verification Algorithms

Safe HaskellNone

Language.Nano.Types

Contents

Synopsis

Configuration Options

data Config Source

Command Line Configuration Options

Constructors

Esc 

Fields

files :: [FilePath]

source files to check

source files to check

source files to check

incdirs :: [FilePath]

path to directory for include specs

path to directory for include specs

path to directory for include specs

TC 

Fields

files :: [FilePath]

source files to check

source files to check

source files to check

incdirs :: [FilePath]

path to directory for include specs

path to directory for include specs

path to directory for include specs

Liquid 

Fields

files :: [FilePath]

source files to check

source files to check

source files to check

incdirs :: [FilePath]

path to directory for include specs

path to directory for include specs

path to directory for include specs

Some Operators on Pred

pAnd :: Pred -> Pred -> PredSource

pOr :: Pred -> Pred -> PredSource

Nano Definition

class IsNano a whereSource

Wrappers around Syntax ------------------

IsNano is a predicate that describes the **syntactic subset** of ECMAScript3 that comprises Nano.

Methods

isNano :: a -> BoolSource

Instances

IsNano PrefixOp 
IsNano InfixOp 
IsNano AssignOp 
IsNano [Statement a] 
IsNano a => IsNano (Maybe a) 
IsNano (Statement a) 
IsNano (LValue a) 
IsNano (VarDecl a) 
IsNano (Expression a) 

checkTopStmt :: Statement SourcePos -> Statement SourcePosSource

Trivial Syntax Checking

Located Values

data Located a Source

Constructors

Loc 

Fields

loc :: !SourcePos
 
val :: a
 

Instances

Functor Located 
Eq a => Eq (Located a) 
PP a => PP (Located a) 
PP t => PP (Env t) 
Symbolic a => Symbolic (Located a) 
IsLocated (Located a) 

class IsLocated a whereSource

IsLocated is a predicate that describes values for which we have a SourcePos

Methods

srcPos :: a -> SourcePosSource

Accessing Spec Annotations

getSpec :: (Statement a -> Maybe Pred) -> [Statement a] -> PredSource

getRequires :: Statement a -> Maybe PredSource

getEnsures :: Statement a -> Maybe PredSource

getAssume :: Statement a -> Maybe PredSource

getAssert :: Statement a -> Maybe PredSource

getInvariant :: Statement a -> PredSource

isSpecification :: Statement a -> BoolSource

returnId :: a -> Id aSource

symbolId :: (IsLocated l, Symbolic x) => l -> x -> Id lSource

mkId :: String -> Id SourcePosSource

Helpers for extracting specifications from ECMAScript3 Statement

Error message

convertError :: PP a => [Char] -> a -> cSource

Deconstructing Id

idName :: Id t -> StringSource

idLoc :: Id t -> tSource