llvm-project/libc/include/strings.yaml
Connector Switch ab22f652a4
[libc] implement strings/str{n}casecmp_l (#130407)
ref:
https://pubs.opengroup.org/onlinepubs/9799919799/functions/strcasecmp_l.html

This patch introduces the `strcasecmp_l` function. At present, the
locale parameter is ignored, making it a stub implementation. This is
consistent with how other locale-related functions, such as `islower_l`,
are treated in our codebase as well as in
[musl](https://github.com/bminor/musl/blob/master/src/string/strcasecmp.c)
and
[bionic](https://cs.android.com/android/platform/superproject/main/+/main:bionic/libc/bionic/strings_l.cpp).

---------

Co-authored-by: Michael Jones <michaelrj@google.com>
2025-03-12 10:49:04 +08:00

97 lines
1.8 KiB
YAML

header: strings.h
header_template: strings.h.def
macros: []
types:
- type_name: size_t
- type_name: locale_t
enums: []
objects: []
functions:
- name: bcmp
standards:
- llvm_libc_ext
return_type: int
arguments:
- type: const void *
- type: const void *
- type: size_t
- name: bcopy
standards:
- llvm_libc_ext
return_type: void
arguments:
- type: const void *
- type: void *
- type: size_t
- name: bzero
standards:
- llvm_libc_ext
return_type: void
arguments:
- type: void *
- type: size_t
- name: ffs
standards:
- POSIX
return_type: int
arguments:
- type: int
- name: ffsl
standards:
- POSIX
return_type: int
arguments:
- type: long
- name: ffsll
standards:
- POSIX
return_type: int
arguments:
- type: long long
- name: index
standards:
- BSDExtensions
return_type: char *
arguments:
- type: const char *
- type: int
- name: rindex
standards:
- BSDExtensions
return_type: char *
arguments:
- type: const char *
- type: int
- name: strcasecmp
standards:
- BSDExtensions
return_type: int
arguments:
- type: const char *
- type: const char *
- name: strcasecmp_l
standards:
- BSDExtensions
return_type: int
arguments:
- type: const char *
- type: const char *
- type: locale_t
- name: strncasecmp
standards:
- BSDExtensions
return_type: int
arguments:
- type: const char *
- type: const char *
- type: size_t
- name: strncasecmp_l
standards:
- BSDExtensions
return_type: int
arguments:
- type: const char *
- type: const char *
- type: size_t
- type: locale_t