[PATCH] D141811: [clang-format] Allow trailing return types in macros
Emilia Dreamer via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Jan 20 18:33:36 PST 2023
rymiel added a comment.
In D141811#4068180 <https://reviews.llvm.org/D141811#4068180>, @HazardyKnusperkeks wrote:
> I thought about `auto NAME() -> int { return 42; }`.
>
> `decltype(auto) a = (b) -> c;` is something else...
I'm not sure how that affects this? Using `decltype(auto)` as in `decltype(auto) NAME() -> int { return 42; }` will recognize the arrow as a trailing return type, but it doesn't really matter as its invalid syntax. I tried to find valid syntax where the arrow would be seen as a trailing return type, and I did with that second example
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D141811/new/
https://reviews.llvm.org/D141811
More information about the cfe-commits
mailing list