mirror of
https://github.com/allankoechke/rust.git
synced 2026-12-05 01:24:03 +00:00
Use .name_str() to format primitive types in error messages
This pull request fixes #84976. The problem described there is caused by this code
506e75cbf8/compiler/rustc_middle/src/ty/error.rs (L161-L166)
using `Debug` formatting (`{:?}`), while the proper solution is to call `name_str()` of `ty::IntTy`, `ty::UintTy` and `ty::FloatTy`, respectively.
For more information about how rustc works, see the rustc dev guide.