Alternatives to pointers?

Dukc ajieskola at gmail.com
Fri Sep 29 08:27:49 UTC 2017


On Friday, 29 September 2017 at 01:51:36 UTC, Jerry wrote:
> Don't know how many times I've accidentially used a pointer as 
> an array.

Using @safe let's the compiler to catch that. Well, in it you 
can't use pointer arithmetic even explicitly, but if you have 
many elements to point at you're usually better off using a real 
array anyway.


More information about the Digitalmars-d mailing list