dplassgit / d2lang

D2 is a strongly-typed, statically-typed, (mostly) inferred-type compiled language.
MIT License
6 stars 0 forks source link

Make the ConstantPropagationOptimizer less conservative #356

Open dplassgit opened 3 weeks ago

dplassgit commented 3 weeks ago

Right now it stops at end of proc, labels, gotos, etc., but if a variable is never changed, it can certainly be propagated throughout the proc/program.

dplassgit commented 3 weeks ago

Still have to be careful about loops