[PATCH] D73548: [clang-tidy] Added option for disabling const qualifiers in readability-qualified-auto
Aaron Ballman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Jan 28 13:45:16 PST 2020
aaron.ballman added inline comments.
================
Comment at: clang-tools-extra/docs/clang-tidy/checks/readability-qualified-auto.rst:41
+ auto *const Bar = cast<const int *>(Baz2);
+ auto *volatile FooBar = cast<int *>(Baz3);
+
----------------
njames93 wrote:
> Quuxplusone wrote:
> > Is it worth adding an example of a double pointer?
> >
> > auto BarN = cast<int **>(FooN);
> >
> > Does that become `auto*` or `auto**` (and why)? My wild guess is that it becomes `auto*` (and because nobody cares about double pointers), but I could be wrong.
> Double pointers are just resolved to `auto *`.
They resolve to `auto *` today but I could see a real argument that they should resolve to `auto **` instead based on the same logic of: don't make the reader infer pointer/references and qualifiers.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D73548/new/
https://reviews.llvm.org/D73548
More information about the cfe-commits
mailing list