From 8f3ee28a3b87f2c14f74f25ecfa04cef46054363 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Per=20=C3=96stlund?= Date: Wed, 20 Jan 2010 12:42:27 +0000 Subject: [PATCH] Added case for Real iterators in elabCallReduction2. git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@4825 f25d12d1-65f4-0310-ae8a-bbce733d8d8e --- Compiler/Static.mo | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/Compiler/Static.mo b/Compiler/Static.mo index 088167de293..b176b1aec1d 100644 --- a/Compiler/Static.mo +++ b/Compiler/Static.mo @@ -1478,13 +1478,21 @@ protected function elabCallReduction2 "help function to elabCallReduction. symbo output list expl; algorithm expl := matchcontinue(e, valLst, id) - local Integer i; - DAE.Exp e1; + local + Integer i; + Real r; + DAE.Exp e1; case(e, {}, id) then {}; - case(e, Values.INTEGER(i)::valLst, id) equation - (e1,_) = Exp.replaceExp(e,DAE.CREF(DAE.CREF_IDENT(id,DAE.ET_OTHER(),{}),DAE.ET_OTHER()),DAE.ICONST(i)); - expl = elabCallReduction2(e, valLst, id); - then e1::expl; + case(e, Values.INTEGER(i)::valLst, id) + equation + (e1,_) = Exp.replaceExp(e,DAE.CREF(DAE.CREF_IDENT(id,DAE.ET_OTHER(),{}),DAE.ET_OTHER()),DAE.ICONST(i)); + expl = elabCallReduction2(e, valLst, id); + then e1::expl; + case(e, Values.REAL(r) :: valLst, id) + equation + (e1,_) = Exp.replaceExp(e, DAE.CREF(DAE.CREF_IDENT(id, DAE.ET_OTHER(), {}), DAE.ET_OTHER()), DAE.RCONST(r)); + expl = elabCallReduction2(e, valLst, id); + then e1 :: expl; end matchcontinue; end elabCallReduction2;