Skip to content

Commit

Permalink
Fixes for #1946
Browse files Browse the repository at this point in the history
- guard Types.subtype2(ty1, tuple(ty2, _)) -> Types.subtype2(ty1, ty2) and 
        Types.subtype2(tuple(ty1, _), ty2) -> Types.subtype2(ty1, ty2)
  to be executed only for normal Modelica and not MetaModelica


git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@14047 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
adrpo committed Nov 24, 2012
1 parent 89032e8 commit 894d611
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Compiler/FrontEnd/Types.mo
Expand Up @@ -1443,12 +1443,14 @@ algorithm
// check of tuple vs. type: i.e. abs(fcallReturningTuple)
// we try subtype of the first tuple element with the other type!
case (DAE.T_TUPLE(tupleType = tp1::_), tp2, _)
equation
equation
false = Config.acceptMetaModelicaGrammar();
true = subtype2(tp1, tp2, requireRecordNamesEqual);
then
true;
case (tp1, DAE.T_TUPLE(tupleType = tp2::_), _)
equation
equation
false = Config.acceptMetaModelicaGrammar();
true = subtype2(tp1, tp2, requireRecordNamesEqual);
then
true;
Expand Down

0 comments on commit 894d611

Please sign in to comment.