Passing static arrays to C

Walter Bright newshound2 at digitalmars.com
Wed Oct 24 02:16:26 PDT 2012


On 10/24/2012 12:54 AM, Jakob Bornecrantz wrote:
 > How are you supposed to pass static arrays to C functions?

C accepts static arrays as pointers, so T[n] in D would be C prototyped as T*.

Pass a pointer to the first element.



More information about the Digitalmars-d mailing list