This will generate an error.

Code:
#include <default.c>

typedef struct
{
var member1;
var member2;
} astruct;

astruct array[10];

function main()
{
astruct tmp;
tmp.member1 = 10;
tmp.member2 = 20;

array[0] = tmp;
}



Quote:

Error in main line 17: machine code generator: can not translate EQU:STRUCT@17::STRUCT@17

< array[0] = tmp; >




Why wont it work? I tried using pointers and allocation on heap and that worked, but id rather do it this way. Just that it doesnt work...

Last edited by Kenchu; 03/07/08 12:41.