aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorForrest Timour <forrest.timour@gmail.com>2020-06-17 14:29:07 -0600
committerMartin Sebor <msebor@redhat.com>2020-06-17 14:34:52 -0600
commita4df94a0330e25efdd9707087fd7365722a47d51 (patch)
treeca06b3321df3d57364c52755b9ea17bc80bc511c
parent94b94c0bb1ca52f2b6912852cb40240efe72e82b (diff)
downloadgcc-a4df94a0330e25efdd9707087fd7365722a47d51.zip
gcc-a4df94a0330e25efdd9707087fd7365722a47d51.tar.gz
gcc-a4df94a0330e25efdd9707087fd7365722a47d51.tar.bz2
Fix typo in attribute access example.
Fix typo in documentation example of access function attribute where the ref-indices should be one-indexed instead of zero-indexed. gcc/ChangeLog: * doc/extend.texi (attribute access): Fix a typo.
-rw-r--r--gcc/doc/extend.texi2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi
index e656e66..10dc32e 100644
--- a/gcc/doc/extend.texi
+++ b/gcc/doc/extend.texi
@@ -2527,7 +2527,7 @@ the @code{memcpy} function.
@smallexample
__attribute__ ((access (read_only, 1))) int puts (const char*);
-__attribute__ ((access (read_only, 1, 2))) void* memcpy (void*, const void*, size_t);
+__attribute__ ((access (read_only, 2, 3))) void* memcpy (void*, const void*, size_t);
@end smallexample
The @code{read_write} access mode applies to arguments of pointer types