1 definition module mTaskInterpret
3 from Data.Functor.Identity import :: Identity
4 from Control.Monad.State import :: State, :: StateT
5 from Data.Monoid import class Semigroup, class Monoid
19 instance toString MTaskMSGRecv
20 instance toString MTaskMSGSend
21 encode :: MTaskMSGSend -> String
22 decode :: String -> MTaskMSGRecv
49 //Conditionals and jumping
69 :: ByteCode a p = BC (BCState -> ([BC], BCState))
70 instance Semigroup (ByteCode a p)
71 instance Monoid (ByteCode a p)
76 sdss :: [(Int, [Char])]
80 class toByteCode a :: a -> [Char]
81 instance toByteCode Int
82 instance toByteCode Bool
83 instance toByteCode Char
84 instance toByteCode String
85 instance toByteCode Long
86 instance toByteCode Button
87 instance toByteCode UserLED
90 instance arith ByteCode
91 instance boolExpr ByteCode
92 instance analogIO ByteCode
93 instance digitalIO ByteCode
94 instance userLed ByteCode
95 //instance If ByteCode Stmt Stmt Stmt
96 //instance If ByteCode e Stmt Stmt
97 //instance If ByteCode Stmt e Stmt
98 instance If ByteCode x y Stmt
100 instance noOp ByteCode
102 instance sds ByteCode
103 instance assign ByteCode
104 instance seq ByteCode
105 instance serial ByteCode
107 //pub :: (ByteCode a b) -> ByteCode a b
109 toMessages :: Int (String, BCState) -> ([MTaskMSGSend], BCState)
110 toSDSUpdate :: Int Int -> [MTaskMSGSend]
112 toByteVal :: BC -> [Char]
113 toReadableByteCode :: (ByteCode a b) -> (String, BCState)
114 toRealByteCode :: (ByteCode a b) -> (String, BCState)