Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gcc.dg/attr-access-read-only-2.c @ 158:494b0b89df80 default tip
...
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 25 May 2020 18:13:55 +0900 |
parents | 1830386684a0 |
children |
line wrap: on
line source
/* PR c/93132 - bogus 'attribute((access))' warning when size-index is specified { dg-do compile } { dg-options "-Wall" } */ void __attribute__ ((access (read_only, 1, 5))) f (void*, int, int, int, int); // { dg-message "previous declaration" } void __attribute__ ((access (read_only, 1, 3))) f (void*, int, int, int, int); // { dg-warning "attribute 'access\\\(read_only, 1, 3\\\)' mismatched positional argument values 3 and 5" } void __attribute__ ((access (read_only, 1, 4))) f (void*, int, int, int, int); // { dg-warning "attribute 'access\\\(read_only, 1, 4\\\)' mismatched positional argument values 4 and 5" } void __attribute__ ((access (read_only, 1, 5))) f (void*, int, int, int, int);