russellmcc added a comment.

Thanks for the explanation!  I do understand your philosophy on this, and agree 
with the desired behavior case you brought up where you have put in new braces.

After thinking about this more, the thing I really care about is that 
clang-format is idempotent with a line filter - i.e., running it twice should 
always have the same effect as running it once.

So, either this fix, or your proposed fix of fixing all lines until the next 
correct indentation would meet that idempotence criteria.

However, I think in this particular case I still prefer my fix - to me, line 
filter is meant to limit the effect of clang-format to just fix a particular 
change and the fallout from that.  However, if the lines _after_ a change were 
wrong before, this feels very unrelated to the change that was made - why is 
now the time to fix these unrelated lines?


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

https://reviews.llvm.org/D54881



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

Reply via email to