Associated constant formatting in docs should mirror source #42759
Labels
C-enhancement
Category: An issue proposing an enhancement or a PR with one.
T-dev-tools
Relevant to the dev-tools subteam, which will review and decide on the PR/issue.
T-rustdoc
Relevant to the rustdoc team, which will review and decide on the PR/issue.
In my source code, I've declared an associated constant as follows:
If I render the rustdocs for
MyStruct
, the following is displayed:Instead, I would like to see:
Or, at the very least:
I've declared the
KIND
constant as a binary number because it serves as a mask. I want the rustdocs to reflect this. Said another way, the representation used in the source code is meaningful, and the rustdocs should preserve that meaning. Note that this should also apply to other representations including hexadecimal. This format-preserving behavior should also apply to other constants, not just associated constants.The text was updated successfully, but these errors were encountered: