ZarkoCA added inline comments.
================ Comment at: clang/include/clang/Sema/Sema.h:12693-12695 void CheckArgAlignment(SourceLocation Loc, NamedDecl *FDecl, - StringRef ParamName, QualType ArgTy, QualType ParamTy); + StringRef ParamName, QualType ArgTy, QualType ParamTy, + const Expr *Arg = nullptr); ---------------- ZarkoCA wrote: > ZarkoCA wrote: > > aaron.ballman wrote: > > > I'm not keen on passing both `Arg` and `ArgTy` such that they can get out > > > of sync. Do all of the places calling `CheckArgAlignment()` have access > > > to the `Expr` so that we can require it be passed (and drop the `ArgTy` > > > parameter)? > > Thanks, that is something I overlooked. > > > > It seems like I can do this everywhere except the call from > > `Sema::CheckConstructorCall`. Trying to figure out whether it's something > > I'm missing. > Thanks for the through review, I think I addressed everything but this > comment. I agree with your concern about having `Arg` and `ArgTy` getting out > of sync. I need to spend more time on that particular call from > `Sema::CheckConstructorCall` and see what can be done. @aaron.ballman I moved the check to its own function and only pass `Expr *Arg` to it. I think this should avoid them getting out of sync. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D118350/new/ https://reviews.llvm.org/D118350 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits