================
@@ -11,6 +11,11 @@ struct S {
void h(const char*) __attribute__((nonnull(1))); // \
expected-error{{invalid for the implicit this argument}}
+
+ void i(this S* self, const char*) __attribute__((nonnull(1)));
+
+ void j(this S* self, const char*) __attribute__((nonnull(3))); // \
+ expected-error{{'nonnull' attribute parameter 1 is out of bounds}}
----------------
Sirraide wrote:
Also add a test to make sure that parameter index `2` works.
https://github.com/llvm/llvm-project/pull/165586
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits