[Gambas-user] gb3: structure declaration not allowed in a different module

Benoît Minisini gambas at ...1...
Sat Nov 19 13:20:07 CET 2011


Le 19/11/2011 08:47, Kevin Fishburne a écrit :
>
> That is super shitty. I'm assuming there's a good reason for that beyond
> my understanding since I've read that page so many times. What's worse
> is that I didn't back up my project prior to migrating the structure
> declarations, so I have to manually undo everything. Damn...
>
>

Sorry for that.

Structures should be used only when:

- You need to call an external C function that requires a C structure.

- You want to send a bunch of structured bytes to a stream, or receive it.

In all other cases, use a class.

At the moment, structure declaration cannot be shared, because all 
source files must be compilable independently. This may change in the 
future as soon as I find a good way to do that.

Regards,

-- 
Benoît Minisini




More information about the User mailing list