Deprecation

Steven Schveighoffer schveiguy at gmail.com
Sat Jan 19 00:11:13 UTC 2019


On 1/18/19 5:53 PM, Ali wrote:
> Hello. I am having an issue with the code below. the out put after 
> compiling is this :
> 
> Deprecation: foreach: loop index implicitly converted from size_t to uint
> 
> the code is :
> 
> auto available = new int[cast(uint) max - min];
>          foreach (uint i, ref a; available)

foreach (i, ref a; available)

>              a = min + i;

a = cast(uint)(min + i);

> 
> Any help would be highly appreciated.

-Steve


More information about the Digitalmars-d-learn mailing list