sstwcw marked an inline comment as done.
sstwcw added inline comments.

================
Comment at: clang/lib/Format/WhitespaceManager.cpp:839-846
         return Style.AlignConsecutiveAssignments.AlignCompound
                    ? C.Tok->getPrecedence() == prec::Assignment
-                   : C.Tok->is(tok::equal);
+                   : C.Tok->is(tok::equal) ||
+                         // In Verilog the '<=' is not a compound assignment,
+                         // thus it is aligned even when the AlignCompound
+                         // option is not set.
+                         (Style.isVerilog() && C.Tok->is(tok::lessequal) &&
----------------
HazardyKnusperkeks wrote:
> Do you need the extra case, or could you just activate `AlignCompound`?
> 
> If you do, can you please add parens, the precedence of `?` and `:` in 
> combination with `||` is at least for me not 100% clear.
If I get you right, you are suggesting that `AlignCompound: false` is there 
only for backward compatibility, and we can make it default to true since we 
don't have to maintain backward compatibility for new things.  I prefer 
consistency.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D142891

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to