HomeFreeBSD

lib/libc/string: document restrict qualification of memccpy() arguments

Description

lib/libc/string: document restrict qualification of memccpy() arguments

POSIX.1-2004 and the upcoming C23 agree that memccpy()'s arguments
are restrict qualified and must not overlap. In 2002, restrict
qualifiers were added to <string.h>'s declaration of the function.
Make things official and document that the arguments must not
overlap.

See also: 61b60edfd3fff20f884419f8097870c7045315c9
Approved by: kib
MFC after: 1 month
MFC to: stable/14

(cherry picked from commit e0d4f419ac41aa91b862f3ceadc32a86abf08572)

Details

Provenance
fuzAuthored on Dec 5 2023, 2:03 PM
Parents
rGddab9e646122: lib/libc/amd64/string: implement strncat() by calling strlen(), memccpy()
Branches
Unknown
Tags
Unknown