PR c/93132 - bogus 'attribute((access))' warning when size-index is specified
authorMartin Sebor <msebor@redhat.com>
Fri, 10 Jan 2020 17:04:00 +0000 (17:04 +0000)
committerMartin Sebor <msebor@gcc.gnu.org>
Fri, 10 Jan 2020 17:04:00 +0000 (10:04 -0700)
commitf25e33fa1b62a6f6c8dddf8e6a7961fae6847a0e
tree88ce9f9f24cbdac4e53f3a41c5ea98f9aac5a2c4
parentb2f5b38042f6a8772237d37cdf20fc139ed0f8fe
PR c/93132 - bogus 'attribute((access))' warning when size-index is specified

gcc/c-family/ChangeLog:

PR c/93132
* c-attribs.c (append_access_attrs): Validate against the translated
access string rather than the human-readable representation.

gcc/testsuite/ChangeLog:

PR c/93132
* gcc.dg/attr-access-read-only-2.c: New test.

From-SVN: r280124
gcc/c-family/ChangeLog
gcc/c-family/c-attribs.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/attr-access-read-only-2.c [new file with mode: 0644]