(unnamed)
text/html
<div><div>Hi,</div><div> </div><div>The ECPG preprocessor converts the code</div><div>"static VARCHAR str1[10], str2[20], str3[30];"</div><div>into</div><div>"static struct varchar_1 { int len; char arr[ 10 ]; } str1 ;</div><div> struct varchar_2 { int len; char arr[ 20 ]; } str2 ;</div><div> struct varchar_3 { int len; char arr[ 30 ]; } str3 ;".</div><div>Storage declaration applies only to the first structure.</div><div> </div><div>The patch in the attachment fixes the bug. Storage declaration will be repeated before each structure.</div><div>The patch is on github too: https://github.com/andr-sokolov/postgresql/commit/c8f8fc7a211938569e7d46c91a428d8cb25b6f9c</div><div> </div><div>--</div><div>Andrey Sokolov</div><div>Arenadata https://arenadata.tech/</div></div>