See [this patch](https://github.com/nielx/rust/commit/9bb7ba3ff02e7d081f51e828daad071cb7ea9b2b), it can be upstreamed right away. Patch has been submitted upstream, see https://github.com/rust-lang/rust/pull/51757