[PATCH] D107950: [clang-format] improve distinction of K&R function definitions vs attributes

Owen Pan via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Aug 12 04:59:01 PDT 2021


owenpan added a comment.

In D107950#2941015 <https://reviews.llvm.org/D107950#2941015>, @MyDeveloperDay wrote:

> I personally think tok::identifier tends to be just too general

However, you can't avoid it as it's used for user-defined types:

  typedef unsigned char byte;
  
  byte *f(a)
  byte a[];
  {
    return a && *a ? a + 1 : 0;
  }

I will try to come up with a solution.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D107950/new/

https://reviews.llvm.org/D107950



More information about the cfe-commits mailing list