[clang] [clang-format] Add AccessModifierMacros option (PR #187521)
Leszek Swirski via cfe-commits
cfe-commits at lists.llvm.org
Fri Mar 20 06:58:18 PDT 2026
LeszekSwirski wrote:
> > > > > I don't think we accept it, you can use the `Macro` option.
> > > >
> > > >
> > > > This unfortunately doesn't work, I tried it already (and it was also tried in the linked bug). As near as I can tell, the token is reconstructed back to the unexpanded version before the token annotator runs, so we lose the expanded form.
> > >
> > >
> > > I think we should fix the `Macros` option instead of adding a new one to work around the bug.
> >
> >
> > That would make sense, I wasn't sure if this would be a layering violation by design since there's other specialised FooMacros that in theory could have just been Macros afaict
>
> Those FooMacros predate `Macros`. We should probably deprecate them if possible. See a related comment [here](https://github.com/llvm/llvm-project/pull/183352#issuecomment-3976676320).
Makes sense. Any thoughts on what layer this should be implemented on? There's not really any precedent to follow, at least none that I can find.
https://github.com/llvm/llvm-project/pull/187521
More information about the cfe-commits
mailing list