@@ -40,9 +40,9 @@ package BackendVarTransform
4040
4141public import DAE ;
4242public import DAELow ;
43- public import Exp ;
4443public import VarTransform ;
4544
45+ protected import Exp ;
4646protected import Util ;
4747
4848public function replaceEquations
@@ -57,13 +57,13 @@ algorithm
5757 outDAELowEquationLst:=
5858 matchcontinue (inDAELowEquationLst,inVariableReplacements)
5959 local
60- Exp . Exp e1_1,e2_1,e1_2,e2_2,e1,e2,e_1,e_2,e;
60+ DAE . Exp e1_1,e2_1,e1_2,e2_2,e1,e2,e_1,e_2,e;
6161 list< DAELow . Equation > es_1,es;
6262 VarTransform . VariableReplacements repl;
6363 DAELow . Equation a;
64- Exp . ComponentRef cr;
64+ DAE . ComponentRef cr;
6565 Integer indx;
66- list< Exp . Exp > expl,expl1,expl2;
66+ list< DAE . Exp > expl,expl1,expl2;
6767 DAELow . WhenEquation whenEqn,whenEqn1;
6868 case ({},_) then {};
6969 case ((DAELow . ARRAY_EQUATION (indx,expl)::es),repl)
@@ -124,9 +124,9 @@ protected function replaceWhenEquation "Replaces variables in a when equation"
124124algorithm
125125 outWhenEqn := matchcontinue(whenEqn,repl)
126126 local Integer i;
127- Exp . ComponentRef cr,cr1;
128- Exp . Exp e,e1,e2;
129- Exp . Type tp;
127+ DAE . ComponentRef cr,cr1;
128+ DAE . Exp e,e1,e2;
129+ DAE . ExpType tp;
130130 DAELow . WhenEquation elsePart,elsePart2;
131131
132132 case (DAELow . WHEN_EQ (i,cr,e,NONE ),repl) equation
@@ -174,13 +174,13 @@ algorithm
174174 outDAELowEquationLst:=
175175 matchcontinue (inDAELowEquationLst,inVariableReplacements)
176176 local
177- Exp .Exp e1_1,e2_1,e1_2,e2_2,e1,e2,e_1,e_2,e;
177+ DAE .Exp e1_1,e2_1,e1_2,e2_2,e1,e2,e_1,e_2,e;
178178 list<DAELow.Equation> es_1,es;
179179 VarTransform.VariableReplacements repl;
180180 DAELow.Equation a;
181- Exp .ComponentRef cr,cr1,cr2;
181+ DAE .ComponentRef cr,cr1,cr2;
182182 Integer indx;
183- list<Exp .Exp> expl,expl1,expl2;
183+ list<DAE .Exp> expl,expl1,expl2;
184184 DAELow.WhenEquation whenEqn,whenEqn1;
185185 case ({},_) then {};
186186 case ((DAELow.ARRAY_EQUATION(indx,expl)::es),repl)
@@ -263,7 +263,7 @@ protected function replaceWhenEquation "Replaces variables in a when equation"
263263algorithm
264264 outWhenEqn := matchcontinue(whenEqn,repl)
265265 local Integer i;
266- Exp .Exp e,e1,e2,cond;
266+ DAE .Exp e,e1,e2,cond;
267267 DAELow.WhenEquation elsePart,elsePart2;
268268 DAELow.Equation eq;
269269 case (DAELow.WHEN_EQ(i,_,cond,eq,NONE),repl)
@@ -284,13 +284,13 @@ protected function shiftUnaryMinusToRHS "
284284Author: BZ, 2008-09
285285Helper function for replaceWhenEquation, moves possible unary minus from lefthand side to right hand side.
286286"
287- input Exp . Exp lhs;
288- input Exp . Exp rhs;
289- output Exp . Exp lhsFixed,rhsFixed;
287+ input DAE . Exp lhs;
288+ input DAE . Exp rhs;
289+ output DAE . Exp lhsFixed,rhsFixed;
290290algorithm (lhsFixed,rhsFixed) := matchcontinue(lhs,rhs)
291291 local
292- Exp . Type tp;
293- Exp . Exp e1,e2;
292+ DAE . ExpType tp;
293+ DAE . Exp e1,e2;
294294 case ((e1 as DAE . CREF (_,_)),e2) then (e1,e2);
295295 case (DAE . UNARY (DAE . UMINUS (tp),e1),e2)
296296 equation
@@ -309,7 +309,7 @@ The function returns the updated list of if-equations."
309309 output list<DAELow.IfEquation> outIfeqns;
310310algorithm
311311 outIfeqns := matchcontinue(ifeqns,repl)
312- local list<Exp .Exp> conds,conds1;
312+ local list<DAE .Exp> conds,conds1;
313313 list<DAELow.Equation> fb,fb1;
314314 list<list<DAELow.Equation>> tbs,tbs1;
315315 list<DAELow.IfEquation> es;
@@ -343,11 +343,11 @@ algorithm
343343 outDAELowEquationLst:=
344344 matchcontinue (inDAELowEquationLst,inVariableReplacements)
345345 local
346- Exp . Exp e1_1,e2_1,e1,e2,e_1,e,e1_2,e2_2;
346+ DAE . Exp e1_1,e2_1,e1,e2,e_1,e,e1_2,e2_2;
347347 list< DAELow . MultiDimEquation > es_1,es;
348348 VarTransform . VariableReplacements repl;
349349 DAELow . Equation a;
350- Exp . ComponentRef cr;
350+ DAE . ComponentRef cr;
351351 list< Integer > dims;
352352 case ({},_) then {};
353353 case ((DAELow . MULTIDIM_EQUATION (left = e1,right = e2,dimSize = dims) :: es),repl)
0 commit comments