Array declaration warning

Paul via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Wed Jun 3 13:45:38 PDT 2015


On Wednesday, 3 June 2015 at 20:33:02 UTC, Ali Çehreli wrote:
> > pathList[][n] ~= CoOrd(cX, cY);
>
> I don't think you need the empty [] there. pathList[n] is one 
> of the paths and you are adding a coordinate to it:

Urgh, *that* is how I was confusing myself, the rest of the code 
'looks right'. Strange that it compiles without warning and the 
spurious [] have no effect though. No doubt there is a reason for 
this that I probably won't understand!

Thanks again

Paul





More information about the Digitalmars-d-learn mailing list