Skip to content

Commit

Permalink
- use Types.elabType instead of Algorithm.getTypeExpType
Browse files Browse the repository at this point in the history
- use match instead of matchcontinue in ClassInf.getStateName


git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@9967 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
adrpo committed Sep 29, 2011
1 parent 80e9189 commit 64af87d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
6 changes: 4 additions & 2 deletions Compiler/FrontEnd/Algorithm.mo
Expand Up @@ -409,9 +409,10 @@ protected
DAE.Type ty;
algorithm
ty := Types.getPropType(p);
t := getTypeExpType(ty);
t := Types.elabType(ty);
end getPropExpType;

/*
protected function getTypeExpType "function: getTypeExpType
Returns the expression type for a given Type module type. Used only by
getPropExpType."
Expand All @@ -434,9 +435,10 @@ algorithm
// record assignments (which actually work just fine). // sjoelund // 2009-05-07
//print("Warning complex_varList not implemented for Array_assign\n");
then fail();
case ((_,_)) then DAE.ET_OTHER(); /* was fail but records must be handled somehow */
case ((_,_)) then DAE.ET_OTHER(); / was fail but records must be handled somehow
end matchcontinue;
end getTypeExpType;
*/

public function makeIf "function: makeIf
This function creates an `DAE.STMT_IF\' construct, checking that the types
Expand Down
5 changes: 2 additions & 3 deletions Compiler/FrontEnd/ClassInf.mo
Expand Up @@ -321,8 +321,7 @@ public function getStateName "function: getStateName
input State inState;
output Absyn.Path outPath;
algorithm
outPath :=
matchcontinue (inState)
outPath := match (inState)
local
Absyn.Path p;
case UNKNOWN(path = p) then p;
Expand Down Expand Up @@ -353,7 +352,7 @@ algorithm
case META_POLYMORPHIC(p) then p;

case _ then Absyn.IDENT("#getStateName failed#");
end matchcontinue;
end match;
end getStateName;

protected function printEventStr
Expand Down

0 comments on commit 64af87d

Please sign in to comment.