[llvm-dev] RFC: should we spell lambdas like functions?

Chris Lattner via llvm-dev
Sat, 07 Jul 2018 15:15:33 -0000

> On Jul 5, 2018, at 12:57 PM, Duncan P. N. Exon Smith via llvm-dev
<llvm-dev at lists.llvm.org> wrote:
>
> I argue we should spell C++ lambdas (and other function-like variables)
like functions, not like variables.
>
> - Use verbs, not nouns.
> - Use lowerCamelCase.
>
> Here's a patch that implements the change to the coding standards:
> https://reviews.llvm.org/D48991 <https://reviews.llvm.org/D48991>
Makes sense to me, I think that all callable values could be named in the same
approach, including function references and std::functions?  Function pointers
are not callable (you need to dereference them) so it is arguable that they
should be capitalized.  It would be nice to include some rationale of why you’re
picking one thing or another in coding standard paragraph.

-Chris

-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20180707/82a34f6d/attachment.html>