opendlang / opend

Boost Software License 1.0
84 stars 18 forks source link

foreach(int idx, v; arr) could do runtime bounds check #70

Open adamdruppe opened 4 months ago

adamdruppe commented 4 months ago

if arr is static length it does VRP

if it is dynamic length i could perhaps do a bound check before entering the loop to ensure it is < int.max

search for

deprecation(fs.loc, "foreach: loop index implicitly converted from `size_t` t

statementsem.d to find the hook