[PATCH] D121370: [clang-format] SortIncludes should support "@import" lines in Objective-C

Konrad Wilhelm Kleine via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 19 03:51:53 PDT 2022


kwk marked 2 inline comments as done.
kwk added a comment.

In D121370#3456223 <https://reviews.llvm.org/D121370#3456223>, @owenpan wrote:

> Should we handle `#import` and `@import` for Object-C only so as to simply the regex for C++?

@owenpan my counter question probably reveals how few things I know about clang-format and how much I still have to learn. I only see `sortCppIncludes` but no `sortObjCIncludes` in the function list in `Format.h`. That said, do you want to introduce that or do you want to put logic in `sortCppIncludes` that knows about the programming language at hand and decides which regex to pick?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D121370



More information about the cfe-commits mailing list