#ponce wrote:
I'm currently using a lot of pointers to perform heavy computation

Has D the equivalent for C's restrict ? More generally, how does D cope with the aliasing of pointers ? I think it's crucial for the code optimizer.

My recollection of reading the spec is that a D compiler is allowed to optimise by assuming no pointer aliasing. But I can't remember at the moment where I read this.

But in the absence of this, you can use contracts to guard against at least the simplest forms of aliasing.

Stewart.

Reply via email to