[PATCH] D107292: [clang] adds warning to alert user when they use alternative tokens as references
Christopher Di Bella via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 3 12:41:26 PDT 2021
cjdb added a comment.
In D107292#2923003 <https://reviews.llvm.org/D107292#2923003>, @rsmith wrote:
> We should also warn on:
>
> - `and` or `bitand` used as a ref-qualifier in a member function declaration
> - `xor` used to declare a block pointer type or block pointer literal
> - `bitand` used as address-of and `and` used to form a GNU address-of-label
> - `compl` used to name a destructor
>
> Of these, I think it's somewhat important to handle ref-qualifiers and probably block pointer types at around the same time that this patch lands (though it doesn't need to be part of this patch) for consistency among "type operators".
I'm happy to work on these patches too. I think this patch should concern itself with declarators, and a second patch should be for expressions. This does drastically expand the scope of the warning, so we should probably come up with a new name for it.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D107292/new/
https://reviews.llvm.org/D107292
More information about the cfe-commits
mailing list