[clang] [clang-format] clang-format-ignore: Add support for double asterisk patterns (PR #110560)

Björn Schäpers via cfe-commits cfe-commits at lists.llvm.org
Thu Oct 24 11:21:06 PDT 2024


================
@@ -49,11 +49,29 @@ bool matchFilePath(StringRef Pattern, StringRef FilePath) {
         return false;
       break;
     case '*': {
-      while (++I < EOP && Pattern[I] == '*') { // Skip consecutive stars.
+      if (I + 1 < EOP && Pattern[I + 1] == '*') {
+        // Handle '**' pattern
----------------
HazardyKnusperkeks wrote:

```suggestion
        // Handle '**' pattern.
```
Always end in full stop.

https://github.com/llvm/llvm-project/pull/110560


More information about the cfe-commits mailing list