Skip to content

Commit

Permalink
- initialize modelica_string variables to NULL otherwise the debugger…
Browse files Browse the repository at this point in the history
… breaks searching for the type of un-initialized meta variables

git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@24559 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
adrpo committed Feb 13, 2015
1 parent 4816fff commit a4bd9d9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Compiler/Template/CodegenC.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -6262,7 +6262,9 @@ match var
case var as VARIABLE(parallelism = NON_PARALLEL(__)) then
let varName = contextCref(var.name,contextFunction,&auxFunction)
let typ = varType(var)
let initVar = match typ case "modelica_metatype" then ' = NULL' else ''
let initVar = match typ case "modelica_metatype"
case "modelica_string" then ' = NULL'
else ''
let &varDecls += if not outStruct then '<%typ%> <%varName%><%initVar%>;<%\n%>' //else ""
let varName = contextCref(var.name,contextFunction,&auxFunction)
let &varInits += initRecordMembers(var, &auxFunction)
Expand Down

0 comments on commit a4bd9d9

Please sign in to comment.