================ @@ -116,26 +118,78 @@ findMembersUsedInInitExpr(const CXXCtorInitializer *Initializer, return Results; } -/// Returns the full source range for the field declaration up to (not -/// including) the trailing semicolumn, including potential macro invocations, -/// e.g. `int a GUARDED_BY(mu);`. +/// Returns the next token after `Loc` (including comment tokens). +static std::optional<Token> getTokenAfter(SourceLocation Loc, ---------------- legrosbuffle wrote:
Thanks for the pointer, I looked at the code in clang-format as I expected to find something like this there, but I did not think of clang-tidy. I'll send a followup to move the code to `Lexer.h`. https://github.com/llvm/llvm-project/pull/122918 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits