Skip to content

Commit

Permalink
- Moved fields in DAE.CALL around; started tail recursion optimization
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@9448 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
sjoelund committed Jul 11, 2011
1 parent 47a0be7 commit b21dd74
Show file tree
Hide file tree
Showing 32 changed files with 619 additions and 618 deletions.
20 changes: 10 additions & 10 deletions Compiler/BackEnd/BackendDAECreate.mo
Expand Up @@ -464,7 +464,7 @@ algorithm
b2 = OptManager.getOption("checkModel");
true = boolOr(b1, b2);

s = DAE.STMT_NORETCALL(DAE.CALL(func_name, args, false, false, DAE.ET_NORETCALL(), DAE.NORM_INLINE()),source);
s = DAE.STMT_NORETCALL(DAE.CALL(func_name, args, DAE.CALL_ATTR(DAE.ET_NORETCALL(), false, false, DAE.NORM_INLINE(), DAE.NO_TAIL())),source);
a = Inline.inlineAlgorithm(DAE.ALGORITHM_STMTS({s}),(SOME(functionTree),{DAE.NORM_INLINE()}));
then
(vars,knvars,extVars,eqns,reqns,ieqns,aeqns,iaeqns,a::algs,ialgs,whenclauses_1,extObjCls,states);
Expand Down Expand Up @@ -1163,7 +1163,7 @@ algorithm
list<DAE.ComponentRef> crlst;
list<BackendDAE.Var> varlst;
BackendDAE.Type btp;
case((e1 as DAE.CALL(path=path,ty=ty as DAE.ET_ARRAY(arrayDimensions=ad,ty=tp)),(vars,i,aeqs,source)))
case((e1 as DAE.CALL(path=path,attr = DAE.CALL_ATTR(ty=ty as DAE.ET_ARRAY(arrayDimensions=ad,ty=tp))),(vars,i,aeqs,source)))
equation
dimSize = Util.listMap(ad, Expression.dimensionSize);
cr = ComponentReference.pathToCref(path);
Expand Down Expand Up @@ -2119,15 +2119,16 @@ algorithm
Boolean t, b;
DAE.ExpType ty;
DAE.InlineType it;
case ((e as DAE.CALL(Absyn.IDENT("delay"), es, t, b, ty, it), (ht,_)))
DAE.CallAttributes attr;
case ((e as DAE.CALL(Absyn.IDENT("delay"), es, attr), (ht,_)))
equation
i = BaseHashTable.get(e,ht);
then ((DAE.CALL(Absyn.IDENT("delay"), DAE.ICONST(i)::es, t, b, ty, it), (ht,i)));
then ((DAE.CALL(Absyn.IDENT("delay"), DAE.ICONST(i)::es, attr), (ht,i)));

case ((e as DAE.CALL(Absyn.IDENT("delay"), es, t, b, ty, it), (ht,i)))
case ((e as DAE.CALL(Absyn.IDENT("delay"), es, attr), (ht,i)))
equation
ht = BaseHashTable.add((e,i),ht);
then ((DAE.CALL(Absyn.IDENT("delay"), DAE.ICONST(i)::es, t, b, ty, it), (ht,i+1)));
then ((DAE.CALL(Absyn.IDENT("delay"), DAE.ICONST(i)::es, attr), (ht,i+1)));

else inTuple;
end matchcontinue;
Expand Down Expand Up @@ -2180,8 +2181,7 @@ algorithm
/*
* adrpo: after a bit of talk with Francesco Casella & Peter Aronsson we will add der($dummy) = 0;
*/
(vars_1,(BackendDAE.EQUATION(DAE.CALL(Absyn.IDENT("der"),
{exp},false,true,DAE.ET_REAL(),DAE.NO_INLINE()),
(vars_1,(BackendDAE.EQUATION(DAE.CALL(Absyn.IDENT("der"),{exp},DAE.callAttrBuiltinReal),
DAE.RCONST(0.0), DAE.emptyElementSource) :: eqns));

end match;
Expand Down Expand Up @@ -2723,13 +2723,13 @@ algorithm
list<DAE.ComponentRef> newStates;
DAE.ComponentRef cr;
String str;
case((DAE.CALL(Absyn.IDENT(name = "der"),{DAE.CALL(Absyn.IDENT(name = "der"),{e1 as DAE.CREF(componentRef=cr)},tuple_ = false,builtin = true)},tuple_ = false,builtin = true),(vars,funcs)))
case((DAE.CALL(path=Absyn.IDENT(name = "der"),expLst={DAE.CALL(path=Absyn.IDENT(name = "der"),expLst={e1 as DAE.CREF(componentRef=cr)})}),(vars,funcs)))
equation
str = ComponentReference.crefStr(cr);
str = stringAppendList({"The model includes derivatives of order > 1 for: ",str,". That is not supported. Real d", str, " = der(", str, ") *might* result in a solvable model"});
Error.addMessage(Error.INTERNAL_ERROR, {str});
then fail();
case((DAE.CALL(Absyn.IDENT(name = "der"),{e1},tuple_ = false,builtin = true),(vars,funcs)))
case((DAE.CALL(path=Absyn.IDENT(name = "der"),expLst={e1}),(vars,funcs)))
equation
e1 = Derive.differentiateExpTime(e1,(vars,funcs));
(e1,_) = ExpressionSimplify.simplify(e1);
Expand Down
31 changes: 17 additions & 14 deletions Compiler/BackEnd/BackendDAEOptimize.mo
Expand Up @@ -3519,7 +3519,7 @@ algorithm
// add equation to calc org var
expCref = Expression.crefExp(cr);
eqns_2 = BackendEquation.equationAdd(BackendDAE.EQUATION(DAE.CALL(Absyn.IDENT("tearing"),
{},false,true,DAE.ET_REAL(),DAE.NO_INLINE()),
{},DAE.callAttrBuiltinReal),
expCref, DAE.emptyElementSource),eqns_1);

tearingeqnid = BackendDAEUtil.equationSize(eqns_2);
Expand Down Expand Up @@ -4772,15 +4772,16 @@ algorithm
Boolean tuple_, builtin;
DAE.InlineType inlineType;
Integer nArgs1, nArgs2;
DAE.CallAttributes attr;
case ( _, {}, _, _, _) then (DAE.RCONST(0.0));
case (currVar::restVar, currDerVar::restDerVar, functionCall as DAE.CALL(expLst=varExpListTotal, tuple_=tuple_, builtin=builtin, ty=et, inlineType=inlineType), derFname, nDerArgs)
case (currVar::restVar, currDerVar::restDerVar, functionCall as DAE.CALL(expLst=varExpListTotal, attr=attr), derFname, nDerArgs)
equation
e = partialAnalyticalDifferentiation(restVar, restDerVar, functionCall, derFname, nDerArgs);
nArgs1 = listLength(varExpListTotal);
nArgs2 = listLength(restDerVar);
varExpList1Added = Util.listReplaceAtWithFill(DAE.RCONST(0.0),nArgs1 + nDerArgs - 1, varExpListTotal ,DAE.RCONST(0.0));
varExpList1Added = Util.listReplaceAtWithFill(DAE.RCONST(1.0),nArgs1 + nDerArgs - (nArgs2 + 1), varExpList1Added,DAE.RCONST(0.0));
derFun = DAE.CALL(derFname, varExpList1Added, tuple_, builtin, et, inlineType);
derFun = DAE.CALL(derFname, varExpList1Added, attr);
then DAE.BINARY(e, DAE.ADD(DAE.ET_REAL()), DAE.BINARY(derFun, DAE.MUL(DAE.ET_REAL()), currDerVar));
end match;
end partialAnalyticalDifferentiation;
Expand All @@ -4801,16 +4802,17 @@ algorithm
Boolean tuple_, builtin;
DAE.InlineType inlineType;
Integer nArgs1, nArgs2;
DAE.CallAttributes attr;
case ({}, _, _, _) then (DAE.RCONST(0.0));
case (currVar::restVar, currDerVar::restDerVar, inState, functionCall as DAE.CALL(path=fname, expLst=varExpListTotal, tuple_=tuple_, builtin=builtin, ty=et, inlineType=inlineType))
case (currVar::restVar, currDerVar::restDerVar, inState, functionCall as DAE.CALL(path=fname, expLst=varExpListTotal, attr=attr))
equation
e = partialNumericalDifferentiation(restVar, restDerVar, inState, functionCall);
absCurr = DAE.LBINARY(DAE.RELATION(currVar,DAE.GREATER(DAE.ET_REAL()),DAE.RCONST(1e-8),-1,NONE()),DAE.OR(DAE.ET_BOOL()),DAE.RELATION(currVar,DAE.LESS(DAE.ET_REAL()),DAE.RCONST(-1e-8),-1,NONE()));
delta = DAE.IFEXP( absCurr, DAE.BINARY(currVar,DAE.MUL(DAE.ET_REAL()),DAE.RCONST(1e-8)), DAE.RCONST(1e-8));
nArgs1 = listLength(varExpListTotal);
nArgs2 = listLength(restVar);
varExpListHAdded = Util.listReplaceAtWithFill(DAE.BINARY(currVar, DAE.ADD(DAE.ET_REAL()),delta),nArgs1-(nArgs2+1), varExpListTotal,DAE.RCONST(0.0));
derFun = DAE.BINARY(DAE.BINARY(DAE.CALL(fname, varExpListHAdded, tuple_, builtin, et, inlineType), DAE.SUB(DAE.ET_REAL()), DAE.CALL(fname, varExpListTotal, tuple_, builtin, et, inlineType)), DAE.DIV(DAE.ET_REAL()), delta);
derFun = DAE.BINARY(DAE.BINARY(DAE.CALL(fname, varExpListHAdded, attr), DAE.SUB(DAE.ET_REAL()), DAE.CALL(fname, varExpListTotal, attr)), DAE.DIV(DAE.ET_REAL()), delta);
then DAE.BINARY(e, DAE.ADD(DAE.ET_REAL()), DAE.BINARY(derFun, DAE.MUL(DAE.ET_REAL()), currDerVar));
end match;
end partialNumericalDifferentiation;
Expand Down Expand Up @@ -5306,7 +5308,7 @@ algorithm
then dxlist;

// extern functions (analytical and numeric)
case (e as DAE.CALL(path=fname, expLst=expList1, tuple_=tuple_, builtin=builtin, ty=et, inlineType=inlineType), xlist, functions, inputVars, paramVars, stateVars, knownVars, allVars, diffVars)
case (e as DAE.CALL(path=fname, expLst=expList1), xlist, functions, inputVars, paramVars, stateVars, knownVars, allVars, diffVars)
equation
dxlist = createDiffListMeta(e,xlist,diffNumCall, SOME((functions, inputVars, paramVars, stateVars, knownVars, allVars, diffVars)));
then dxlist;
Expand Down Expand Up @@ -5544,16 +5546,17 @@ algorithm
list<DAE.ComponentRef> diffVars;
DAE.FunctionTree functions;
list<tuple<Integer,DAE.derivativeCond>> conditions;
DAE.CallAttributes attr;
//Option<tuple<DAE.FunctionTree, list<BackendDAE.Var>, list<BackendDAE.Var>, list<BackendDAE.Var>, list<BackendDAE.Var>, list<BackendDAE.Var>>> inTpl;
// extern functions (analytical)
case ((e as DAE.CALL(path=fname, expLst=expList1, tuple_=tuple_, builtin=builtin, ty=et, inlineType=inlineType), x, SOME((functions, inputVars, paramVars, stateVars, knownVars, allVars, diffVars))))
case ((e as DAE.CALL(path=fname, expLst=expList1), x, SOME((functions, inputVars, paramVars, stateVars, knownVars, allVars, diffVars))))
equation
nArgs = listLength(expList1);
(DAE.FUNCTION_DER_MAPPER(derivativeFunction=derFname,conditionRefs=conditions), tp) = Derive.getFunctionMapper(fname, functions);
expList2 = deriveExpListwrtstate(expList1, nArgs, conditions, x, functions, inputVars, paramVars, stateVars, knownVars, allVars, diffVars);
e1 = partialAnalyticalDifferentiation(expList1, expList2, e, derFname, listLength(expList2));
then e1;
case ((e as DAE.CALL(path=fname, expLst=expList1, tuple_=tuple_, builtin=builtin, ty=et, inlineType=inlineType), x, SOME((functions, inputVars, paramVars, stateVars, knownVars, allVars, diffVars))))
case ((e as DAE.CALL(path=fname, expLst=expList1), x, SOME((functions, inputVars, paramVars, stateVars, knownVars, allVars, diffVars))))
equation
//(SOME((functions, inputVars, paramVars, stateVars, knownVars, diffVars))) = inTpl;
nArgs = listLength(expList1);
Expand Down Expand Up @@ -5582,13 +5585,13 @@ algorithm
//sin(x)
case (inExp1,inExp2,inOrgExp1 as DAE.CALL(path=Absyn.IDENT("sin")))
equation
e = DAE.BINARY(inExp1, DAE.MUL(DAE.ET_REAL()), DAE.CALL(Absyn.IDENT("cos"),{inExp2},false,true,DAE.ET_REAL(),DAE.NO_INLINE()));
e = DAE.BINARY(inExp1, DAE.MUL(DAE.ET_REAL()), DAE.CALL(Absyn.IDENT("cos"),{inExp2},DAE.callAttrBuiltinReal));
(e,_) = ExpressionSimplify.simplify(e);
then e;
// cos(x)
case (inExp1,inExp2,inOrgExp1 as DAE.CALL(path=Absyn.IDENT("cos")))
equation
e = DAE.UNARY(DAE.UMINUS(DAE.ET_REAL()), DAE.BINARY(inExp1,DAE.MUL(DAE.ET_REAL()), DAE.CALL(Absyn.IDENT("sin"),{inExp2},false,true,DAE.ET_REAL(),DAE.NO_INLINE())));
e = DAE.UNARY(DAE.UMINUS(DAE.ET_REAL()), DAE.BINARY(inExp1,DAE.MUL(DAE.ET_REAL()), DAE.CALL(Absyn.IDENT("sin"),{inExp2},DAE.callAttrBuiltinReal)));
(e,_) = ExpressionSimplify.simplify(e);
then e;
// ln(x)
Expand All @@ -5600,13 +5603,13 @@ algorithm
// log10(x)
case (inExp1,inExp2,inOrgExp1 as DAE.CALL(path=Absyn.IDENT("log10")))
equation
e = DAE.BINARY(inExp1, DAE.DIV(DAE.ET_REAL()), DAE.BINARY(inExp2, DAE.MUL(DAE.ET_REAL()), DAE.CALL(Absyn.IDENT("log"),{DAE.RCONST(10.0)},false,true,DAE.ET_REAL(),DAE.NO_INLINE())));
e = DAE.BINARY(inExp1, DAE.DIV(DAE.ET_REAL()), DAE.BINARY(inExp2, DAE.MUL(DAE.ET_REAL()), DAE.CALL(Absyn.IDENT("log"),{DAE.RCONST(10.0)},DAE.callAttrBuiltinReal)));
(e,_) = ExpressionSimplify.simplify(e);
then e;
// exp(x)
case (inExp1,inExp2,inOrgExp1 as DAE.CALL(path=Absyn.IDENT("exp")))
equation
e = DAE.BINARY(inExp1,DAE.MUL(DAE.ET_REAL()), DAE.CALL(Absyn.IDENT("exp"),{inExp2},false,true,DAE.ET_REAL(),DAE.NO_INLINE()));
e = DAE.BINARY(inExp1,DAE.MUL(DAE.ET_REAL()), DAE.CALL(Absyn.IDENT("exp"),{inExp2},DAE.callAttrBuiltinReal));
(e,_) = ExpressionSimplify.simplify(e);
then e;
// sqrt(x)
Expand All @@ -5615,7 +5618,7 @@ algorithm
e = DAE.BINARY(
DAE.BINARY(DAE.RCONST(1.0),DAE.DIV(DAE.ET_REAL()),
DAE.BINARY(DAE.RCONST(2.0),DAE.MUL(DAE.ET_REAL()),
DAE.CALL(Absyn.IDENT("sqrt"),{inExp2},false,true,DAE.ET_REAL(),DAE.NO_INLINE()))),DAE.MUL(DAE.ET_REAL()),inExp1);
DAE.CALL(Absyn.IDENT("sqrt"),{inExp2},DAE.callAttrBuiltinReal))),DAE.MUL(DAE.ET_REAL()),inExp1);
(e,_) = ExpressionSimplify.simplify(e);
then e;
// abs(x)
Expand Down Expand Up @@ -5670,7 +5673,7 @@ algorithm
equation
z1 = DAE.BINARY(inExp1, DAE.DIV(et), inOrgExp1);
z1 = DAE.BINARY(inOrgExp2, DAE.MUL(et), z1);
z2 = DAE.CALL(Absyn.IDENT("log"), {inOrgExp1}, false, true, DAE.ET_REAL(), DAE.NO_INLINE());
z2 = DAE.CALL(Absyn.IDENT("log"), {inOrgExp1}, DAE.callAttrBuiltinReal);
z2 = DAE.BINARY(inExp2, DAE.MUL(et), z2);
z1 = DAE.BINARY(z1, DAE.ADD(et), z2);
z2 = DAE.BINARY(inOrgExp1, DAE.POW(et), inOrgExp2);
Expand Down
14 changes: 6 additions & 8 deletions Compiler/BackEnd/BackendDAETransform.mo
Expand Up @@ -2751,12 +2751,12 @@ algorithm
ds2 = Expression.crefExp(dummystate1);
dds1 = Expression.crefExp(derdummystate);
dds2 = Expression.crefExp(derdummystate1);
cont1 = DAE.RELATION(DAE.CALL(Absyn.IDENT("abs"),{dse2},false,true,DAE.ET_REAL(),DAE.NO_INLINE()),DAE.LESS(DAE.ET_REAL()),DAE.CALL(Absyn.IDENT("abs"),{dse1},false,true,DAE.ET_REAL(),DAE.NO_INLINE()),0,NONE());
cont1 = DAE.RELATION(DAE.CALL(Absyn.IDENT("abs"),{dse2},DAE.callAttrBuiltinReal),DAE.LESS(DAE.ET_REAL()),DAE.CALL(Absyn.IDENT("abs"),{dse1},DAE.callAttrBuiltinReal),0,NONE());
((cont,_)) = Expression.traverseExp(dxdyecont, traversingComponentRefToPre, 0);
icont = DAE.LBINARY(DAE.CALL(Absyn.IDENT("initial"),{},false,true,DAE.ET_BOOL(),DAE.NO_INLINE()),DAE.OR(DAE.ET_BOOL()),cont);
icont = DAE.LBINARY(DAE.CALL(Absyn.IDENT("initial"),{},DAE.callAttrBuiltinBool),DAE.OR(DAE.ET_BOOL()),cont);
eq = BackendDAE.EQUATION(dxdye,DAE.IFEXP(icont,ds2,ds1),DAE.emptyElementSource);
dae = BackendEquation.equationAddDAE(eq,dae);
deq = BackendDAE.EQUATION(DAE.CALL(Absyn.IDENT("der"),{dxdye},false,true,DAE.ET_REAL(),DAE.NO_INLINE()),DAE.IFEXP(icont,dds2,dds1),DAE.emptyElementSource);
deq = BackendDAE.EQUATION(DAE.CALL(Absyn.IDENT("der"),{dxdye},DAE.callAttrBuiltinReal),DAE.IFEXP(icont,dds2,dds1),DAE.emptyElementSource);
dae = BackendEquation.equationAddDAE(deq,dae);

wc = BackendDAE.WHEN_CLAUSE(dxdyecont,{BackendDAE.REINIT(dsxy,ds2,DAE.emptyElementSource)},NONE());
Expand Down Expand Up @@ -2809,7 +2809,7 @@ algorithm

case((e as DAE.CREF(_,_), i))
then
((DAE.CALL(Absyn.IDENT("pre"),{e},false,true,DAE.ET_REAL(),DAE.NO_INLINE()), i ));
((DAE.CALL(Absyn.IDENT("pre"),{e},DAE.callAttrBuiltinReal), i ));

case(inExp) then inExp;

Expand Down Expand Up @@ -2873,8 +2873,7 @@ algorithm
Debug.fcall("bltdump", BackendDump.debugStrCrefStr, ("Chosen dummy: ",dummy_der," as dummy state\n"));
changedeqns = BackendDAEUtil.eqnsForVarWithStates(mt, stateno);
stateexp = Expression.crefExp(state);
tp = Expression.typeof(stateexp);
stateexpcall = DAE.CALL(Absyn.IDENT("der"),{stateexp},false,true,tp,DAE.NO_INLINE());
stateexpcall = DAE.CALL(Absyn.IDENT("der"),{stateexp},DAE.callAttrBuiltinReal);
dummyderexp = Expression.crefExp(dummy_der);
(dae,m,mt) = replaceDummyDer(stateexpcall, dummyderexp, dae, m, mt, changedeqns)
"We need to change variables in the differentiated equations and in the equations having the dummy derivative" ;
Expand Down Expand Up @@ -3183,8 +3182,7 @@ algorithm
reqns = BackendDAEUtil.eqnsForVarWithStates(mt, stateno);
changedeqns = Util.listUnionOnTrue(deqns, reqns, intEq);
stateexp = Expression.crefExp(state);
tp = Expression.typeof(stateexp);
stateexpcall = DAE.CALL(Absyn.IDENT("der"),{stateexp},false,true,tp,DAE.NO_INLINE());
stateexpcall = DAE.CALL(Absyn.IDENT("der"),{stateexp},DAE.callAttrBuiltinReal);
dummyderexp = Expression.crefExp(dummy_der);
(dae,m,mt) = replaceDummyDer(stateexpcall, dummyderexp, dae, m, mt, changedeqns)
"We need to change variables in the differentiated equations and in the equations having the dummy derivative" ;
Expand Down
7 changes: 4 additions & 3 deletions Compiler/BackEnd/BackendDAEUtil.mo
Expand Up @@ -3436,7 +3436,7 @@ algorithm outExp := matchcontinue(inExp)
expl = Util.listMap1(varLst,Expression.generateCrefsExpFromExpVar,cr);
i = listLength(expl);
true = intGt(i,0);
e_new = DAE.CALL(name,expl,false,false,t,DAE.NO_INLINE());
e_new = DAE.CALL(name,expl,DAE.CALL_ATTR(t,false,false,DAE.NO_INLINE(),DAE.NO_TAIL()));
restpl = Expression.traverseExp(e_new, traversingextendArrExp, (funcs,true));
then
(restpl);
Expand Down Expand Up @@ -5205,6 +5205,7 @@ algorithm
Boolean b;
DAE.InlineType i;
DAE.ExpType ty;
DAE.CallAttributes attr;

case({},vars) then {};

Expand Down Expand Up @@ -5234,13 +5235,13 @@ algorithm
then
(DAE.UNARY(op,e1)::expl);

case(DAE.CALL(path,expl2,tpl,b,ty,i)::expl,vars)
case(DAE.CALL(path,expl2,attr)::expl,vars)
equation
repl = makeZeroReplacements(vars);
(expl2 as _::_) = ifBranchesFreeFromVar(expl2,vars);
expl = ifBranchesFreeFromVar(expl,vars);
then
(DAE.CALL(path,expl2,tpl,b,ty,i)::expl);
(DAE.CALL(path,expl2,attr)::expl);

case(_::expl,vars)
equation
Expand Down
6 changes: 3 additions & 3 deletions Compiler/BackEnd/BackendDump.mo
Expand Up @@ -102,17 +102,17 @@ algorithm
list<DAE.Exp> args;
DAE.Exp e1,e2;
Expression.Type ty;
case( DAE.CALL(path = Absyn.IDENT("DIVISION"), expLst = {e1,e2,DAE.SCONST(_)}, tuple_ = false,builtin = true,ty = ty,inlineType = DAE.NO_INLINE()), _, _)
case( DAE.CALL(path = Absyn.IDENT("DIVISION"), expLst = {e1,e2,DAE.SCONST(_)}, attr = DAE.CALL_ATTR(ty = ty)), _, _)
equation
s = ExpressionDump.printExp2Str(DAE.BINARY(e1,DAE.DIV(ty),e2),stringDelimiter,opcreffunc, SOME(printCallFunction2StrDIVISION));
then
s;
case( DAE.CALL(path = Absyn.IDENT("DIVISION_ARRAY_SCALAR"),expLst = {e1,e2,DAE.SCONST(_)}, tuple_ = false,builtin = true,ty =ty,inlineType = DAE.NO_INLINE()), _, _)
case( DAE.CALL(path = Absyn.IDENT("DIVISION_ARRAY_SCALAR"),expLst = {e1,e2,DAE.SCONST(_)}, attr = DAE.CALL_ATTR(ty =ty)), _, _)
equation
s = ExpressionDump.printExp2Str(DAE.BINARY(e1,DAE.DIV_ARRAY_SCALAR(ty),e2),stringDelimiter,opcreffunc, SOME(printCallFunction2StrDIVISION));
then
s;
case( DAE.CALL(path = Absyn.IDENT("DIVISION_SCALAR_ARRAY"),expLst = {e1,e2,DAE.SCONST(_)}, tuple_ = false,builtin = true,ty =ty,inlineType = DAE.NO_INLINE()), _, _)
case( DAE.CALL(path = Absyn.IDENT("DIVISION_SCALAR_ARRAY"),expLst = {e1,e2,DAE.SCONST(_)}, attr = DAE.CALL_ATTR(ty =ty)), _, _)
equation
s = ExpressionDump.printExp2Str(DAE.BINARY(e1,DAE.DIV_SCALAR_ARRAY(ty),e2),stringDelimiter,opcreffunc, SOME(printCallFunction2StrDIVISION));
then
Expand Down

0 comments on commit b21dd74

Please sign in to comment.