﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
1680	Error in generated C code for arrays with undetermined size	chenouard-r	chenouard-r	"I build a ""simple"" example with a model and a function based on an array of an undetermined size. I think I conformed to Modelica language, but some other Modelica compilers also don't achieve in executing this code (mainly a problem with my use of sum function). The modelica code and 2 of the main C files generated by OpenModelica are joined as attached files. I use OpenModelica Compiler 1.8.0 (r10946). 

I got the following errors when compiling:
{{{
Test.Test1.c: In function ‘eqFunction_3’:
Test.Test1.c:279: error: expected expression before ‘:’ token
Test.Test1.c:289: error: ‘$P$reductionFoldTmpA’ undeclared (first use in this function)
Test.Test1.c:289: error: (Each undeclared identifier is reported only once
Test.Test1.c:289: error: for each function it appears in.)
Test.Test1.c:289: error: ‘$P$reductionFoldTmpB’ undeclared (first use in this function)
Test.Test1.c: In function ‘eqFunction_6’:
Test.Test1.c:385: error: expected expression before ‘:’ token
Test.Test1.c:395: error: ‘$P$reductionFoldTmpA’ undeclared (first use in this function)
Test.Test1.c:395: error: ‘$P$reductionFoldTmpB’ undeclared (first use in this function)
}}}

I suppose there is a problem when reformulating and generating the C code. The ':' symbol is used to state C arrays and some temporary variables are not define before use."	defect	new	high		Backend				chenouard-r
