================
@@ -1174,6 +1192,18 @@ template <> struct MappingTraits<FormatStyle> {
         Style.PackConstructorInitializers = FormatStyle::PCIS_CurrentLine;
     }
 
+    // If BinPackParameters was specified but PackParameters was not, 
initialize
+    // the latter from the former for backwards compatibility.
+    if (IsChromiumOrMozilla) {
+      if (BinPackParameters &&
+          (Style.PackParameters == FormatStyle::PPS_CurrentLine)) {
+        Style.PackParameters = FormatStyle::PPS_BinPack;
+      }
+    } else if (!BinPackParameters &&
+               (Style.PackParameters == FormatStyle::PPS_BinPack)) {
----------------
HazardyKnusperkeks wrote:

```suggestion
               Style.PackParameters == FormatStyle::PPS_BinPack) {
```

https://github.com/llvm/llvm-project/pull/101882
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to