why static array can be reassigned with new allocation?

matheus matheus at gmail.com
Sat Oct 15 10:31:16 UTC 2022


On Friday, 14 October 2022 at 20:19:20 UTC, Ali Çehreli wrote:
> ...
> The compiler does not perform detailed analysis of all code. 
> Since that 5 could be a runtime expression, the compiler does 
> not check it at compile time.
> ...

Yes but in this case it's known during the compiling time 
(Literal 5), couldn't this be checked and prevented?

Matheus.


More information about the Digitalmars-d mailing list