Skip to content
This repository has been archived by the owner on May 18, 2019. It is now read-only.

Commit

Permalink
More append underscores to Modelica names
Browse files Browse the repository at this point in the history
See e.g. Modelica.Fluid.Examples.Tanks.ThreeTanks
  • Loading branch information
rfranke authored and OpenModelica-Hudson committed Jan 31, 2017
1 parent fd5058e commit 2099c8b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Compiler/Template/CodegenCppCommon.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -502,6 +502,7 @@ template daeExpCrefRhsArrayBox2(Text var,DAE.Type type, Context context, Text &p
else
var
end daeExpCrefRhsArrayBox2;

template daeExpRecordCrefRhs(DAE.Type ty, ComponentRef cr, Context context, Text &preExp, Text &varDecls, SimCode simCode, Text& extraFuncs,
Text& extraFuncsDecl, Text extraFuncsNamespace, Text stateDerVectorName /*=__zDot*/, Boolean useFlatArrayNotation)
::=
Expand All @@ -512,7 +513,7 @@ case T_COMPLEX(complexClassType = record_state, varLst = var_lst) then
let record_type_name = underscorePath(ClassInf.getStateName(record_state))
let ret_type = '<%record_type_name%>RetType'
let ret_var = tempDecl(ret_type, &varDecls)
let &preExp += '<%contextFunName(record_type_name, context)%>(<%vars%>,<%ret_var%>);<%\n%>/*testfunction*/'
let &preExp += '<%contextFunName(record_type_name, context)%>(<%vars%>,<%ret_var%>);<%\n%>'
'<%ret_var%>'
end daeExpRecordCrefRhs;

Expand Down Expand Up @@ -1662,7 +1663,7 @@ template structParams(String structName,String varName,list<Var> exps)
::=
let params = (exps |> e => match e
case TYPES_VAR(__) then
'<%varName%>.<%name%>=<%structName%>.<%name%>;'
'<%varName%>.<%name%>_ = <%structName%>.<%name%>_;'
;separator="\n" )
params
end structParams;
Expand Down

0 comments on commit 2099c8b

Please sign in to comment.