On Thursday, 7 June 2012 at 17:17:07 UTC, Artur Skawina wrote:
On 06/07/12 18:04, bearophile wrote:
Page 46: #pragma no_alias Are we going to need something like
that (or "restrict") in D too?
"restrict" functionality - yes, but it's probably better done
the other way around -
restrict as default and "alias" when necessary. Reusing the
keyword could work too,
if template parameters is the only thing that can clash.
artur
For this to work, the compiler would need to accurately imply
aliasing with a 100% accuracy, to spit out errors. And if that
was possible we would not need programmers hints at all. With
restrict as a keyword, at least the programmer is aware of how
"dangerous" that code is.