diff options
Diffstat (limited to 'assignment-13/uFPL/C.dcl')
-rw-r--r-- | assignment-13/uFPL/C.dcl | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/assignment-13/uFPL/C.dcl b/assignment-13/uFPL/C.dcl index 3b25183..938707b 100644 --- a/assignment-13/uFPL/C.dcl +++ b/assignment-13/uFPL/C.dcl @@ -2,7 +2,6 @@ definition module uFPL.C from Data.Maybe import :: Maybe -from uFPL.Arduino import :: Button from uFPL.Util import class print :: Signedness = Sig | Unsig @@ -13,28 +12,23 @@ from uFPL.Util import class print | CTInt Signedness | CTLong Signedness | CTVoid - | CTArray CType | CTStruct String :: CExpr - = CEButton Button - | CEGlobal String + = CEGlobal String | CEInfix String CExpr CExpr | CEApp String [CExpr] | CEBool Bool | CEInt Int | CEChar Char - | CEBArray Int [Bool] - | CEIArray Int [Int] + | CEString String | CEIf CExpr CExpr CExpr | CERef CExpr - | CEDeref CExpr | CEStruct [(String, CExpr)] :: CBody = CBReturn (Maybe CExpr) | CBIf CExpr CBody [(CExpr, CBody)] (Maybe CBody) - | CBWhile CExpr CBody | CBAssign String CExpr | CBSeq CBody CBody | CBEmpty @@ -49,8 +43,7 @@ from uFPL.Util import class print } :: CFun = - { params :: [(Int, CType)] - , body :: CBody + { body :: CBody , type :: CType , name :: String } |