[Bug c++/79961] Should diagnose when '__nonnull__' attribute is applied to implicit this argument

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Mar 8 18:56:00 GMT 2017


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79961

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
We certainly should allow __attribute__((nonnull)) on methods, even when that
includes nonnull (implicit) also for this.  I find error on that weird, there
is nothing wrong specifying that this is non-null, so perhaps just warning (but
question is how to call it and under which of -Wall/-W or none of that enable
it).


More information about the Gcc-bugs mailing list