[PATCH] D103825: [clang] Do not crash when ArgTy is null in CheckArgAlignment
Adam Czachorowski via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Jun 8 09:40:53 PDT 2021
adamcz added reviewers: kadircet, hokein.
adamcz added a comment.
FYI The ArgTy.isNull() check is sufficient to fix this. The Arg->containsErrors() is not - it's false in this case, since it seems CXXDefaultArgExpr with RecoveryExpr inside seems to not contains errors, according to containsError(). I can't tell if that's by design, or a bug.
Haojian, please let me know if you think Arg->containsError() should be true or if we should be testing somewhere else, or just drop it and accept that CheckArgAlignment may be called with RecoveryExpr and have it check for ArgTy->isNull().
Basically, let me know what you think about this. Thanks!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D103825/new/
https://reviews.llvm.org/D103825
More information about the cfe-commits
mailing list