convert int[][] to int**

Andrea Fontana nospam at example.com
Thu Feb 20 08:55:45 PST 2014


On Thursday, 20 February 2014 at 16:47:43 UTC, bearophile wrote:
> Andrea Fontana:
>
>> I have a C api that need a int** params that represent a 
>> int[][]. How can I convert from d to c to pass it? For simple 
>> arrays, array.ptr seems to work...
>
> One way to do it (untested):
>
> int** pp = myDArray.map!(a => a.ptr).array.ptr;
>
> Bye,
> bearophile

Ok, so it seems there's no "built-in" ways...


More information about the Digitalmars-d-learn mailing list