[PATCH] D79354: [clang-format] [PR34574] Handle [[nodiscard]] attribute in class declaration

Krasimir Georgiev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue May 5 12:58:35 PDT 2020


krasimir added a comment.

I'm not familiar with ObjC, but hope this helps:

  % cat ~/example.mm   # left as-is by clang-format without D79354                 
  (int)f : (int)arg {
    struct A as[] = {{a11, a12},  //
                     {a21, a22},  //
                     {nil, 0}};
    return 0;
  }
  % bin/clang-format ~/example.mm  # clang-format with D79354
  (int)f : (int)arg {
    struct A as[] = {
      {a11, a12},     //
          {a21, a22}, //
      {
        nil, 0
      }
    };
    return 0;
  }
  % 


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D79354





More information about the cfe-commits mailing list