Re:The Road to Rust 1.0
by pkolaczk on Tuesday September 16, 2014 @10:54AM
(#8324774)
VM could do see all the functions and do whole-program analysis. Inlining is an orthogonal concept.
[ Parent
| on HN ]
You could in theory, but that analysis would likely be really slow.
In any case, without the type system and compiler to enforce the discipline the programmer is going to lose a lot of control and predictability.
Not necessarily. As you said, Rust encodes that information in type signatures. Exactly the same information can be used in a VM and it could do escape analysis one method at a time then.