HazardyKnusperkeks added a comment. Maybe do not limit to `JsTypeColon` but all colons? What about something like `f(some_template<Variable>).method()`? I'd have to check where it breaks if there isn't a template in the argument, but I'd guess not before the paren.
================ Comment at: clang/lib/Format/TokenAnnotator.cpp:4953-4958 if (Left.is(TT_TemplateCloser) && Right.is(TT_TemplateOpener)) return true; + if (Left.is(TT_TemplateCloser) && Right.is(tok::r_paren) && + (!Right.Next || Right.Next->isNot(TT_JsTypeColon))) { + return true; + } ---------------- Could you merge this? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D140267/new/ https://reviews.llvm.org/D140267 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits