Why __memrchr vs. memrchr ?
Why such a scheme is used in GLIBC:
declare + define __memrchr, and than
# ifdef __USE_GNU # define memrchr(s, c, n) __memrchr ((s), (c), (n)) # endif
? memrchr is not the GNU extension, is it?
Thanks in advance.
Hi,
Quoted 9 lines · Denis Zaitsev
Why such a scheme is used in GLIBC:
declare + define
__memrchr, and than# ifdef __USE_GNU # define memrchr(s, c, n) __memrchr ((s), (c), (n)) # endif? memrchr is not the GNU extension, is it?
According to memchr(3),
"The memrchr() function is a GNU extension, available since glibc 2.1.91".
Signature · 1 line
ldv
Quoted 7 lines · Dmitry V. Levin
Hi,
Quoted 4 lines · Denis Zaitsev
Why such a scheme is used in GLIBC:
declare + define
__memrchr, and than
Quoted 8 lines
Quoted 5 lines
# ifdef __USE_GNU # define memrchr(s, c, n) __memrchr ((s), (c), (n)) # endif? memrchr is not the GNU extension, is it?
According to memchr(3),
"Thememrchr()function is a GNU extension, available since glibc 2.1.91".
Oh, I'm sorry. This fact is omited from the texinfo GLIBC documentation...
Thanks.
Quoted 12 lines · Denis Zaitsev
Quoted 11 lines · Dmitry V. Levin
Hi,
Quoted 8 lines · Denis Zaitsev
Why such a scheme is used in GLIBC:
declare + define
__memrchr, and than# ifdef __USE_GNU # define memrchr(s, c, n) __memrchr ((s), (c), (n)) # endif
Quoted 7 lines
Quoted 4 lines
Quoted 1 line
? memrchr is not the GNU extension, is it?
According to memchr(3),
"Thememrchr()function is a GNU extension, available since glibc 2.1.91".Oh, I'm sorry. This fact is omited from the texinfo GLIBC documentation...
It's in the Library Summary:
`void * memrchr (const void *BLOCK, int C, size_t SIZE)'
`string.h' (GNU): *Note Search Functions::.
Andreas
Signature · 3 lines
Andreas Jaeger, [email protected], http://www.suse.de/~aj SuSE Linux AG, Maxfeldstr. 5, 90409 Nürnberg, Germany GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
Quoted 7 lines · Andreas Jaeger
Quoted 5 lines · Denis Zaitsev
Quoted 3 lines · Dmitry V. Levin
According to memchr(3),
"Thememrchr()function is a GNU extension, available since glibc 2.1.91".
Quoted 6 lines
Quoted 2 lines
Oh, I'm sorry. This fact is omited from the texinfo GLIBC documentation...
It's in the Library Summary:
`void * memrchr (const void *BLOCK, int C,size_tSIZE)'
`string.h' (GNU): *Note Search Functions::.
Indeed, it's shortly marked as (GNU) here and there. But that's not described in the texi manual. So, below is the tiny patch. Please, apply it.
string.texi renamed from string.texi.orig +2 -0
@@ -1625,6 +1625,8 @@ This function is a GNU extension. The function @code{memrchr} is like @code{memchr}, except that it searches backwards from the end of the block defined by @var{block} and @var{size} (instead of forwards from the front). + +This function is a GNU extension. @end deftypefun @comment string.h