[PATCH] D138446: [clang-format][docs] Add ability to link to specific config options
Aaron Ballman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 12 06:15:01 PST 2023
aaron.ballman accepted this revision.
aaron.ballman added a comment.
In D138446#3942006 <https://reviews.llvm.org/D138446#3942006>, @rymiel wrote:
> I consulted a little bit with a friend who has a little bit of experience with sphinx and they suggested making a simple custom extension for this. But given that there is no custom sphinx logic right now at all, I don't feel great adding something that novel to the whole of clang docs just for this page of clang-format
Unless the custom extension is something that is committed to version control, fetched alongside the rest of the repo, and "just works" for folks without setup, I think it's best to avoid it. Otherwise we'll have to update the sphinx build bots, downstreams will have to react to it, and users will have a harder time building the docs locally. It's not that we can't do it if it's the right solution; it's that it's better to avoid something requiring manual intervention if we can.
As best I know, the way you've done things in this patch is the way Sphinx is expected to work for arbitrary anchors (despite being pretty janky IMO), so this LGTM!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D138446/new/
https://reviews.llvm.org/D138446
More information about the cfe-commits
mailing list