rustdoc: Consider adding CCI for the HIR expressions of public constants #132443
Labels
C-enhancement
Category: An issue proposing an enhancement or a PR with one.
T-rustdoc
Relevant to the rustdoc team, which will review and decide on the PR/issue.
When a constant is inlined into another crate, we are forced to always show the evaluated/folded version of the constant. This is because we don't have access to the original HIR in the metadata.
This could be a situation where we can use (rust-lang/rfcs#3662) to store the original expression for public constants (that could potentially be inlined by other crates) so that we don't have the cross-crate issue. Might be applicable to other cross-crate inconsistencies too (though hopefully the type alias one will be resolved by lazy_type_alias).
Adapted from a post by @camelid in #131975 (comment)
The text was updated successfully, but these errors were encountered: