================
@@ -698,7 +698,11 @@ void 
CodeGenFunction::markAsIgnoreThreadCheckingAtRuntime(llvm::Function *Fn) {
 bool CodeGenFunction::requiresReturnValueCheck() const {
   return requiresReturnValueNullabilityCheck() ||
          (SanOpts.has(SanitizerKind::ReturnsNonnullAttribute) && CurCodeDecl &&
-          CurCodeDecl->getAttr<ReturnsNonNullAttr>());
+          CurCodeDecl->getAttr<ReturnsNonNullAttr>()) ||
+         (SanOpts.has(SanitizerKind::Alignment) && CurCodeDecl &&
+          ((isa<FunctionDecl>(CurCodeDecl) &&
----------------
rnk wrote:

This FunctionDecl only serves to match the other condition, which I don't think 
we need.

https://github.com/llvm/llvm-project/pull/239729
_______________________________________________
llvm-branch-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

Reply via email to