mirror of
https://github.com/compiler-explorer/compiler-explorer.git
synced 2026-12-02 00:39:23 -06:00
The current Rust formatter on site doesn't support modern rust syntax like async/await. This is because the formatter in production runs using Rust 2015. Forcing edition=2018 allows more modern rust code to be formatted properly. Rustfmt is also shipped directly as a Rust component now, so we don't have to install it separately. For what it's worth, attempting to "Ctrl Shift I" format the code in this shortlink demonstrates the problem https://godbolt.org/z/aP4669KEW