aboutsummaryrefslogtreecommitdiff
path: root/lib/ubsan/ubsan_handlers.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/ubsan/ubsan_handlers.h')
-rw-r--r--lib/ubsan/ubsan_handlers.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/ubsan/ubsan_handlers.h b/lib/ubsan/ubsan_handlers.h
index 350eb91d1bf9..5857bc2495f5 100644
--- a/lib/ubsan/ubsan_handlers.h
+++ b/lib/ubsan/ubsan_handlers.h
@@ -136,8 +136,10 @@ struct NonNullReturnData {
SourceLocation AttrLoc;
};
-/// \brief Handle returning null from function with returns_nonnull attribute.
+/// \brief Handle returning null from function with the returns_nonnull
+/// attribute, or a return type annotated with _Nonnull.
RECOVERABLE(nonnull_return, NonNullReturnData *Data)
+RECOVERABLE(nullability_return, NonNullReturnData *Data)
struct NonNullArgData {
SourceLocation Loc;
@@ -145,8 +147,10 @@ struct NonNullArgData {
int ArgIndex;
};
-/// \brief Handle passing null pointer to function with nonnull attribute.
+/// \brief Handle passing null pointer to a function parameter with the nonnull
+/// attribute, or a _Nonnull type annotation.
RECOVERABLE(nonnull_arg, NonNullArgData *Data)
+RECOVERABLE(nullability_arg, NonNullArgData *Data)
/// \brief Known CFI check kinds.
/// Keep in sync with the enum of the same name in CodeGenFunction.h