klimek added inline comments.

================
Comment at: lib/Format/WhitespaceManager.cpp:678
     // Indent with tabs only when there's at least one full tab.
-    if (FirstTabWidth + Style.TabWidth <= Spaces) {
+    if (Style.TabWidth <= Spaces) {
       Spaces -= FirstTabWidth;
----------------
Why is this not just if (FirstTabWidth <= Spaces) then?


================
Comment at: unittests/Format/FormatTest.cpp:9372
+  FormatStyle::UseTabStyle OldTabStyle = Alignment.UseTab;
+  unsigned OldTabWidth = Alignment.TabWidth;
+  Alignment.UseTab = FormatStyle::UT_Always;
----------------
Instead of doing the save/restore dance, just put it at the end of a test or 
create a new test (or alternatively create a new style as copy and then change 
the settings on that).


Repository:
  rC Clang

https://reviews.llvm.org/D48259



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

Reply via email to