owenpan added inline comments.

================
Comment at: clang/lib/Format/ContinuationIndenter.cpp:40
 static unsigned getLengthToMatchingParen(const FormatToken &Tok,
-                                         const std::vector<ParenState> &Stack) 
{
+                                         const SmallVector<ParenState> &Stack) 
{
   // Normally whether or not a break before T is possible is calculated and
----------------
curdeius wrote:
> owenpan wrote:
> > curdeius wrote:
> > > Sorry for a late comment. I think that in a parameter list, we should use 
> > > `SmallVectorBase` to avoid changing the type if the inplace element count 
> > > changes. That's not important now though.
> > Hmm. I can't find an example of `SmallVectorBase` in llvm-project sources, 
> > though.
> Typo, it's Impl: https://llvm.org/doxygen/classllvm_1_1SmallVectorImpl.html
Good catch, though `ArrayRef` is more appropriate in this case. See 
https://llvm.org/docs/ProgrammersManual.html#llvm-adt-smallvector-h. Fixed in 
a7789d6.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D129466

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

Reply via email to