Skip to content

Commit

Permalink
- reverted changes in unparseType
Browse files Browse the repository at this point in the history
- added dump function for subscripts


git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@20560 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
Volker Waurich committed May 12, 2014
1 parent a6c1408 commit 343c89f
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
8 changes: 8 additions & 0 deletions Compiler/FrontEnd/ExpressionDump.mo
Expand Up @@ -415,6 +415,14 @@ algorithm
end match;
end printSubscriptStr;

public function printSubscriptLstStr
"Print a list of Subscripts into a String."
input list<DAE.Subscript> inSubscriptLst;
output String outString;
algorithm
outString := stringDelimitList(List.map(inSubscriptLst,printSubscriptStr)," , ");
end printSubscriptLstStr;

public function printExpListStr
" prints a list of expressions with commas between expressions."
input list<DAE.Exp> expl;
Expand Down
4 changes: 2 additions & 2 deletions Compiler/FrontEnd/Types.mo
Expand Up @@ -2107,7 +2107,7 @@ algorithm
res = Absyn.pathString(ClassInf.getStateName(ci_state));
st_str = ClassInf.printStateStr(ci_state);
bc_tp_str = unparseType(bc_tp);
res = stringAppendList({"subType(",res," ",st_str," bc:",bc_tp_str,")"});
res = stringAppendList({"(",res," ",st_str," bc:",bc_tp_str,")"});
then
res;

Expand All @@ -2133,7 +2133,7 @@ algorithm
equation
tystrs = List.map(tys, unparseType);
tystr = stringDelimitList(tystrs, ", ");
res = stringAppendList({"TUPLE(",tystr,")"});
res = stringAppendList({"(",tystr,")"});
then
res;

Expand Down

0 comments on commit 343c89f

Please sign in to comment.