Agda-2.5.2: A dependently typed functional programming language and proof assistant

Safe Haskell | None
Language | Haskell2010

Agda.Compiler.JS.Syntax

# Documentation

data Exp #

Constructors

Self |
Local LocalId |
Global GlobalId |
Undefined |
String String |
Char Char |
Integer Integer |
Double Double |
Lambda Nat Exp |
Object (Map MemberId Exp) |
Apply Exp [Exp] |
Lookup Exp MemberId |
If Exp Exp Exp |
BinOp Exp String Exp |
PreOp String Exp |
Const String |
PlainJS String | Arbitrary JS code.

Instances

Show Exp # |
Methods showsPrec :: Int -> Exp -> ShowS # show :: Exp -> String # showList :: [Exp] -> ShowS #
Globals Exp # |
Methods globals :: Exp -> Set GlobalId #
Uses Exp # |
Methods uses :: Exp -> Set [MemberId] #
Pretty Exp # |
Methods pretty :: Nat -> Int -> Exp -> String #

newtype LocalId #

Constructors

LocalId Nat |

Instances

Eq LocalId # |
Methods (==) :: LocalId -> LocalId -> Bool # (/=) :: LocalId -> LocalId -> Bool #
Ord LocalId # |
Methods compare :: LocalId -> LocalId -> Ordering # (<) :: LocalId -> LocalId -> Bool # (<=) :: LocalId -> LocalId -> Bool # (>) :: LocalId -> LocalId -> Bool # (>=) :: LocalId -> LocalId -> Bool # max :: LocalId -> LocalId -> LocalId # min :: LocalId -> LocalId -> LocalId #
Show LocalId # |
Methods showsPrec :: Int -> LocalId -> ShowS # show :: LocalId -> String # showList :: [LocalId] -> ShowS #
Pretty LocalId # |
Methods pretty :: Nat -> Int -> LocalId -> String #

newtype GlobalId #

Constructors

GlobalId [String] |

Instances

Eq GlobalId # |
Methods (==) :: GlobalId -> GlobalId -> Bool # (/=) :: GlobalId -> GlobalId -> Bool #
Ord GlobalId # |
Methods compare :: GlobalId -> GlobalId -> Ordering # (<) :: GlobalId -> GlobalId -> Bool # (<=) :: GlobalId -> GlobalId -> Bool # (>) :: GlobalId -> GlobalId -> Bool # (>=) :: GlobalId -> GlobalId -> Bool # max :: GlobalId -> GlobalId -> GlobalId # min :: GlobalId -> GlobalId -> GlobalId #
Show GlobalId # |
Methods showsPrec :: Int -> GlobalId -> ShowS # show :: GlobalId -> String # showList :: [GlobalId] -> ShowS #
Pretty GlobalId # |
Methods pretty :: Nat -> Int -> GlobalId -> String #

newtype MemberId #

Constructors

MemberId String |

Instances

Eq MemberId # |
Methods (==) :: MemberId -> MemberId -> Bool # (/=) :: MemberId -> MemberId -> Bool #
Ord MemberId # |
Methods compare :: MemberId -> MemberId -> Ordering # (<) :: MemberId -> MemberId -> Bool # (<=) :: MemberId -> MemberId -> Bool # (>) :: MemberId -> MemberId -> Bool # (>=) :: MemberId -> MemberId -> Bool # max :: MemberId -> MemberId -> MemberId # min :: MemberId -> MemberId -> MemberId #
Show MemberId # |
Methods showsPrec :: Int -> MemberId -> ShowS # show :: MemberId -> String # showList :: [MemberId] -> ShowS #
Pretty MemberId # |
Methods pretty :: Nat -> Int -> MemberId -> String #

data Export #

Constructors

Export |
Fields expName :: [MemberId] isCoind :: Bool defn :: Exp

Instances

Show Export # |
Methods showsPrec :: Int -> Export -> ShowS # show :: Export -> String # showList :: [Export] -> ShowS #
Globals Export # |
Methods globals :: Export -> Set GlobalId #
Uses Export # |
Methods uses :: Export -> Set [MemberId] #

data Module #

Constructors

Module |
Fields modName :: GlobalId exports :: [Export] postscript :: Maybe Exp

Instances

Show Module # |
Methods showsPrec :: Int -> Module -> ShowS # show :: Module -> String # showList :: [Module] -> ShowS #
Globals Module # |
Methods globals :: Module -> Set GlobalId #
Pretty Module # |
Methods pretty :: Nat -> Int -> Module -> String #

class Uses a where #

Minimal complete definition

uses

Methods

uses :: a -> Set [MemberId] #

Instances

Uses Export # |
Methods uses :: Export -> Set [MemberId] #
Uses Exp # |
Methods uses :: Exp -> Set [MemberId] #
Uses a => Uses [a] # |
Methods uses :: [a] -> Set [MemberId] #
Uses a => Uses (Map k a) # |
Methods uses :: Map k a -> Set [MemberId] #

class Globals a where #

Minimal complete definition

globals

Methods

globals :: a -> Set GlobalId #

Instances

Globals Module # |
Methods globals :: Module -> Set GlobalId #
Globals Export # |
Methods globals :: Export -> Set GlobalId #
Globals Exp # |
Methods globals :: Exp -> Set GlobalId #
Globals a => Globals [a] # |
Methods globals :: [a] -> Set GlobalId #
Globals a => Globals (Map k a) # |
Methods globals :: Map k a -> Set GlobalId #