From 90d01e948649a8d75333a0378dc86f846da5ffd1 Mon Sep 17 00:00:00 2001 From: vruge Date: Sun, 25 Mar 2018 16:05:29 +0200 Subject: [PATCH] fixed inline - use VariableReplacements refs ticket:4841 Belonging to [master]: - OpenModelica/OMCompiler#2314 - OpenModelica/OpenModelica-testsuite#895 --- Compiler/FrontEnd/Inline.mo | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Compiler/FrontEnd/Inline.mo b/Compiler/FrontEnd/Inline.mo index 970278583b9..b87c275476c 100644 --- a/Compiler/FrontEnd/Inline.mo +++ b/Compiler/FrontEnd/Inline.mo @@ -1136,8 +1136,7 @@ algorithm equation // use type of cref, since var type is different // and has no hint on array or record type - tp = ComponentReference.crefTypeFull(cr); - oBody = listAppend(oBody, {DAE.STMT_ASSIGN(exp1 = Expression.crefExp(cr), exp = exp, source=DAE.emptyElementSource, type_=tp)}); + oRepl = addOptBindingReplacements(cr,binding,oRepl); oOutputs = cr :: oOutputs; then ();