| Safe Haskell | Safe-Inferred |
|---|
Derive.REnv
Contents
Description
This is a serializable subset of DeriveT.Val and DeriveT.Environ.
It omits pitches, which are code and can't be serialized.
Synopsis
- data Environ
- to_map :: Environ -> Map EnvKey.Key Val
- from_list :: [(EnvKey.Key, Val)] -> Environ
- convert :: Environ -> DeriveT.Environ
- lookup :: EnvKey.Key -> Environ -> Maybe Val
- null :: Environ -> Bool
- data Val
- data ConstantPitch = ConstantPitch !Pitch.ScaleId !Pitch.Note !Pitch.NoteNumber
- class ToVal a where
- type Expr = Expr.Expr Val
- type Call = Expr.Call Val
- type Term = Expr.Term Val
Documentation
convert :: Environ -> DeriveT.Environ Source #
val
This is like DeriveT.Val, except missing fields that can't be
serialized, or require Deriver and hence couldn't go in a module below
Deriver without incurring a circular dependency.
Namely: DeriveT.VPitch, DeriveT.VCFunction.
NOTE [val-and-minival].
Constructors
| VNum !(ScoreT.Typed Signal.Y) | |
| VAttributes !Attrs.Attributes | |
| VControlRef !DeriveT.ControlRef | |
| VConstantPitch !ConstantPitch | |
| VNotePitch !Pitch.Pitch | |
| VStr !Expr.Str | |
| VQuoted !Expr | |
| VList ![Val] |
data ConstantPitch Source #
Constructors
| ConstantPitch !Pitch.ScaleId !Pitch.Note !Pitch.NoteNumber |
Instances
| Show ConstantPitch Source # | |
Defined in Derive.REnv Methods showsPrec :: Int -> ConstantPitch -> ShowS # show :: ConstantPitch -> String # showList :: [ConstantPitch] -> ShowS # | |
| Eq ConstantPitch Source # | |
Defined in Derive.REnv Methods (==) :: ConstantPitch -> ConstantPitch -> Bool # (/=) :: ConstantPitch -> ConstantPitch -> Bool # | |
| ToVal ConstantPitch Source # | |
Defined in Derive.REnv Methods to_val :: ConstantPitch -> Val Source # | |
This duplicates Typecheck, but then so does this whole module.
In any case, it's convenient for creaing Environs.
TODO But I wish I could reuse Typecheck.ToVal, otherwise I have to add an extra instance declaration for each type.
Minimal complete definition
Nothing