@@ -320,8 +320,8 @@ uniontype EEquation
320320 end EQ_TERMINATE ;
321321
322322 record EQ_REINIT "a reinit equation"
323- Absyn . ComponentRef cref "the variable to initialize" ;
324- Absyn . Exp expReinit "the new value" ;
323+ Absyn . Exp cref "the variable to initialize" ;
324+ Absyn . Exp expReinit "the new value" ;
325325 Comment comment;
326326 SourceInfo info;
327327 end EQ_REINIT ;
@@ -412,7 +412,7 @@ public uniontype Statement "The Statement type describes one algorithm statement
412412 end ALG_TERMINATE ;
413413
414414 record ALG_REINIT
415- Absyn . ComponentRef cref;
415+ Absyn . Exp cref;
416416 Absyn . Exp newValue;
417417 Comment comment;
418418 SourceInfo info;
@@ -1518,10 +1518,10 @@ algorithm
15181518 then
15191519 true ;
15201520
1521- case (EQ_REINIT (cref = cr1, expReinit = e1), EQ_REINIT (cref = cr2, expReinit = e2 ))
1521+ case (EQ_REINIT (), EQ_REINIT ())
15221522 equation
1523- true = Absyn . expEqual(e1,e2 );
1524- true = Absyn . crefEqual(cr1,cr2 );
1523+ true = Absyn . expEqual(eq1 . cref, eq2 . cref );
1524+ true = Absyn . expEqual(eq1 . expReinit, eq2 . expReinit );
15251525 then
15261526 true ;
15271527
@@ -2055,7 +2055,7 @@ algorithm
20552055
20562056 case ALG_REINIT ()
20572057 then Absyn . ALGORITHMITEM (Absyn . ALG_NORETCALL (Absyn . CREF_IDENT ("reinit" , {}),
2058- Absyn . FUNCTIONARGS ({Absyn . CREF ( stmt. cref) , stmt. newValue}, {})), NONE (), stmt. info);
2058+ Absyn . FUNCTIONARGS ({stmt. cref, stmt. newValue}, {})), NONE (), stmt. info);
20592059
20602060 case ALG_NORETCALL (Absyn . CALL (function_= functionCall,functionArgs= functionArgs),_,info)
20612061 then Absyn . ALGORITHMITEM (Absyn . ALG_NORETCALL (functionCall,functionArgs),NONE (),info);
@@ -2286,7 +2286,7 @@ algorithm
22862286
22872287 case EQ_REINIT ()
22882288 algorithm
2289- outArg := inFunc(Absyn . CREF ( inEquation. cref) , outArg);
2289+ outArg := inFunc(inEquation. cref, outArg);
22902290 outArg := inFunc(inEquation. expReinit, outArg);
22912291 then
22922292 outArg;
@@ -2383,7 +2383,7 @@ algorithm
23832383
23842384 case ALG_REINIT ()
23852385 algorithm
2386- outArg := inFunc(Absyn . CREF ( inStatement. cref) , outArg);
2386+ outArg := inFunc(inStatement. cref, outArg);
23872387 then
23882388 inFunc(inStatement. newValue, outArg);
23892389
@@ -2635,12 +2635,12 @@ algorithm
26352635 then
26362636 (EQ_TERMINATE (e1, comment, info), arg);
26372637
2638- case (EQ_REINIT (cr1, e1 , comment, info), traverser, _)
2638+ case (EQ_REINIT (e1, e2 , comment, info), traverser, _)
26392639 equation
2640- (cr1 , arg) = traverseComponentRefExps(cr1, traverser, inArg);
2641- (e1 , arg) = traverser(e1 , arg);
2640+ (e1 , arg) = traverser(e1 , inArg);
2641+ (e2 , arg) = traverser(e2 , arg);
26422642 then
2643- (EQ_REINIT (cr1, e1 , comment, info), arg);
2643+ (EQ_REINIT (e1, e2 , comment, info), arg);
26442644
26452645 case (EQ_NORETCALL (e1, comment, info), traverser, arg)
26462646 equation
@@ -3090,10 +3090,10 @@ algorithm
30903090
30913091 case (ALG_REINIT (), traverser, arg)
30923092 algorithm
3093- (Absyn . CREF (cref) , arg) := traverser(Absyn . CREF ( inStatement. cref) , arg);
3093+ (e1 , arg) := traverser(inStatement. cref, arg);
30943094 (e2, arg) := traverser(inStatement. newValue, arg);
30953095 then
3096- (ALG_REINIT (cref , e2, inStatement. comment, inStatement. info), arg);
3096+ (ALG_REINIT (e1 , e2, inStatement. comment, inStatement. info), arg);
30973097
30983098 case (ALG_NORETCALL (e1, comment, info), traverser, arg)
30993099 equation
0 commit comments