On Friday, 22 January 2016 at 08:39:06 UTC, Dibyendu Majumdar
wrote:
On Friday, 22 January 2016 at 01:53:53 UTC, Chris Wright wrote:
On Thu, 21 Jan 2016 21:52:06 +, Dibyendu Majumdar wrote:
Hi
I have C code where the struct has a trailing array member:
struct matrix {
int rows;
int
On Friday, 22 January 2016 at 01:53:53 UTC, Chris Wright wrote:
On Thu, 21 Jan 2016 21:52:06 +, Dibyendu Majumdar wrote:
Hi
I have C code where the struct has a trailing array member:
struct matrix {
int rows;
int cols;
double data[1];
};
D has bounds checking, which makes this
Dibyendu Majumdar:
On Thursday, 21 January 2016 at 21:52:06 UTC, Dibyendu Majumdar
wrote:
How should this be translated to D? Will D's array access allow
data elements to be accessed beyond the size declared?
Take a look at the code I've written here:
http://rosettacode.org/wiki/Sokoban#Faste
On Thu, 21 Jan 2016 21:52:06 +, Dibyendu Majumdar wrote:
> Hi
>
> I have C code where the struct has a trailing array member:
>
> struct matrix {
>int rows;
>int cols;
>double data[1];
> };
>
> In C code this is allocated dynamically to be variable size. The array
> is used just
Hi
I have C code where the struct has a trailing array member:
struct matrix {
int rows;
int cols;
double data[1];
};
In C code this is allocated dynamically to be variable size. The
array is used just as normal.
How should this be translated to D? Will D's array access allow
data ele