3 ms·
> we can already see this by compiling build and proc macro crates with optimizations, it's just not the default and they still have to be compiled once. I'm
by vlakreeh 3y ago
> we can already see this by compiling build and proc macro crates with optimizations, it's just not the default and they still have to be compiled once.
I'm hopeful something like watt (https://github.com/dtolnay/watt https://github.com/dtolnay/watt) will land in Cargo that'll allow us to ship pre-compiled wasm blobs for proc-macros so we can just have sandboxed binaries.
- insanitybit 3y agoThat'll be great for proc-macros, although it won't work for build scripts.
- adastra22 3y agoWhy not?
- insanitybit 3y agoIt could, in theory. But build scripts can do arbitrary things so the wasm sandbox would need to allow for that.
- adastra22 3y agoI think the whole point is to prevent build scripts from doing arbitrary things. The sandbox should give access to the source code being built, record changes to these files (and/or new files generated in the same directories), and that's about it.
- insanitybit 3y agoThat's a cool idea but it would be a major breaking change. For proc-macros it's less of a major breaking change, though it is absolutely still one.