about array setting

dfun boyseeyou at gmail.com
Fri Jan 19 22:01:38 PST 2007


about array setting
on this page http://www.digitalmars.com/d/arrays.html
give an example

int[3] s;
int* p;
s[] = 3;		// same as s[0] = 3, s[1] = 3, s[2] = 3
p[0..2] = 3;		// same as p[0] = 3, p[1] = 3

pring error => Error: Access Violation
why?
use dmd 1.0



More information about the Digitalmars-d mailing list