Closed
Description
We keep repeating this, but it adds no helpful information for readers of the call site, it's just boilerplate and noise.
Steps:
- change https://github.com/rust-lang/rust/blob/b66cf6fe168e10dcbfed4320a5e84c0c28eee814/compiler/rustc_middle/src/ty/context.rs#L2302 to use
mk_const_internal
instead ofmk_const
. This is what generates the currentmk_const
function. - Create a
mk_const
function next to https://github.com/rust-lang/rust/blob/b66cf6fe168e10dcbfed4320a5e84c0c28eee814/compiler/rustc_middle/src/ty/context.rs#L2644 that takes two arguments and forwards them to amk_const_internal(ty::ConstS { val, kind }
- fix up all the
mk_const
call sites to make them stop usingty::ConstS
and instead pass the two fields as arguments