Foreach loops on static arrays error message

Andrea Fontana via Digitalmars-d digitalmars-d at puremagic.com
Thu Jul 6 03:01:59 PDT 2017


On Thursday, 6 July 2017 at 09:06:18 UTC, Guillaume Chatelet 
wrote:
>> ubyte[256] data;
>> foreach(ubyte i; 0..256) {
>>   ubyte x = data[i];
>> }
>> 	
>
> Yes. Much better. What's the rewrite in this case? Using a 
> size_t internally and casting to ubyte?


I was just wondering


More information about the Digitalmars-d mailing list