[Gambas-user] gb3 RC1: using structures to replace the loss of Mk$ functions

Jussi Lahtinen jussi.lahtinen at ...626...
Sun Apr 3 15:33:32 CEST 2011


> With respect to Doriano, how would one use the memcpy() statement in
> GAMBAS? I see from Wikipedia that "void *memcpy(void *dest, const void
> *src, size_t n);" shows the syntax in C. My two questions are, how do
> you call external library functions in gb, and how would you translate
> the C syntax to gb syntax?
>


Public Extern memcpy(pDest As Pointer, pSrc As Pointer, size As Integer) In
"libc:6"

Then example in Gambas;
memcpy(Array1.Data, Array2.Data, Array2.Count * SizeOf(gb.Integer))


Jussi



More information about the User mailing list