curdeius added a comment.

Still WIP but I'd like to have some feedback.



================
Comment at: clang/lib/Format/UnwrappedLineFormatter.cpp:283
+
+              // FIXME: Use IndentTracker to avoid loop?
+              // Find the last line with lower level.
----------------
Because of this I consider this patch as a WIP still.
I'm all ears if anyone has an idea how to efficiently find the "parent" line of 
the current one, i.e. a line with level smaller by one.
There are places where we use a stack for similar purposes. I'm not sure if 
there's already something existing I could use.

As a last resort, I'll add a stack of Lines that start a new level in 
`LevelIndentTracker` and update it in `nextLine()`.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D117142

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

Reply via email to