[PATCH] Keep track of indentation levels in static initializers for correct indentation with tabs.

Daniel Jasper djasper at google.com
Fri Oct 11 22:03:15 PDT 2013


  I still not sure that this works when we adapt to local style. Consider this case:

  Assume IndentWidth = 2, UseTab = UT_ForIndentation. Then:

    void f() {
      if (a) {
      f();  // This is wrong but not formatted.
      aaaaaa( // Format only this line.
          parameter); // How many tabs are used for this line. I would guess 2, although 1 would be correct.
      }
    }

  I might be wrong though. Also, feel free to check this in as is and wait for somebody to file a bug ;-).

http://llvm-reviews.chandlerc.com/D1797

BRANCH
  svn

ARCANIST PROJECT
  clang



More information about the cfe-commits mailing list