4 ms·
As far as I'm aware, it's always been the other way around: Miri adds some features on top of rustc's const-evaluation code. The limitations of the latter are m
by LegionMammal978 1y ago
As far as I'm aware, it's always been the other way around: Miri adds some features on top of rustc's const-evaluation code. The limitations of the latter are mainly self-imposed, due to the issues of exposing the different runtime models to programs. (E.g., you don't want to create allocations in const code that get deallocated at runtime.) Indeed, since 2019, the full functionality can be exposed with the unstable -Zunleash-the-miri-inside-of-you flag [0].
[0] https://github.com/rust-lang/rust/pull/56123 https://github.com/rust-lang/rust/pull/56123
- LoganDark 1y agoI'm pretty sure we're in agreement? Miri is capable of a lot more but there are self-imposed limitations on what you're allowed to do in const.