 rustc's implementation https://github.com/rust-lang/rust/pull/81869