X-Git-Url: https://git.martlubbers.net/?a=blobdiff_plain;f=sem.icl;h=31221ca3c289dca1c46587fe0318c684a25dd3cd;hb=6f035b0bf9e10d215a2d8d6198d29f7727877cad;hp=709071c9cdde16695b64b55a5f09408a2062ae60;hpb=9e1081469910f9b70a1ea713f431aadf385c52b7;p=cc1516.git diff --git a/sem.icl b/sem.icl index 709071c..31221ca 100644 --- a/sem.icl +++ b/sem.icl @@ -35,7 +35,8 @@ instance toString SemError where toString (ParseError p e) = concat [ toString p,"SemError: ParseError: ", e] toString (Error e) = "SemError: " +++ e - toString (UnifyErrorStub t1 t2) = toString (UnifyError {line=0,col=0} t1 t2) + toString (UnifyErrorStub t1 t2) = toString (UnifyError {line=0,col=0} t1 +t2) toString (UnifyError p t1 t2) = concat [ toString p, "SemError: Cannot unify types. Expected: ", @@ -95,7 +96,8 @@ typeExpr (Op2Expr p e1 BiOr e2) = undef typeExpr (Op2Expr p e1 BiCons e2) = undef //typeExpr (FunExpr Pos FunCall) = undef //typeExpr (EmptyListExpr Pos) = undef -//typeExpr (VarExpr Pos VarDef) = undef //when checking var-expr, be sure to put the infered type +//typeExpr (VarExpr Pos VarDef) = undef //when checking var-expr, be sure to +//put the infered type //in the context class unify a :: Type a -> Env Type