Recognize and advertise POSIX 2024 support.

Update feature macros for interfaces added to POSIX 2024.

This commit begins the work of implementing POSIX 2024, which was
largely already implemented as extensions.
This commit is contained in:
Jonas 'Sortie' Termansen 2024-06-23 13:19:16 +02:00
parent 50792cb986
commit 82fd2d4c92
7 changed files with 125 additions and 113 deletions

View File

@ -6,7 +6,7 @@ if [ "$#" = 0 ]; then
set i686-sortix x86_64-sortix
fi
for target; do
for feature in "" "-D_POSIX_C_SOURCE=200809L" "-D_XOPEN_SOURCE=700" "-D_SORTIX_SOURCE"; do
for feature in "" "-D_POSIX_C_SOURCE=202405L" "-D_XOPEN_SOURCE=800" "-D_SORTIX_SOURCE"; do
for std in \
"-ansi -pedantic-errors" \
"-std=c89 -pedantic-errors" \

View File

@ -62,7 +62,7 @@
#define _C11_SOURCE
#endif
#if !defined(_POSIX_C_SOURCE)
#define _POSIX_C_SOURCE 200809L
#define _POSIX_C_SOURCE 202405L
#endif
#if !defined(_XOPEN_SOURCE)
#define _XOPEN_SOURCE 700
@ -93,7 +93,10 @@
/* Particular XSI revisions imply certain POSIX revisions. */
#if defined(_XOPEN_SOURCE)
#if 700 <= _XOPEN_SOURCE - 0
#if 800 <= _XOPEN_SOURCE - 0
#undef _POSIX_C_SOURCE
#define _POSIX_C_SOURCE 202405L
#elif 700 <= _XOPEN_SOURCE - 0
#undef _POSIX_C_SOURCE
#define _POSIX_C_SOURCE 200809L
#elif 600 <= _XOPEN_SOURCE - 0
@ -155,7 +158,9 @@
/* Determine which revision of POSIX is used. */
#ifdef _POSIX_C_SOURCE
#if 200809L <= _POSIX_C_SOURCE - 0
#if 202405L <= _POSIX_C_SOURCE - 0
#define __USE_POSIX 202405L
#elif 200809L <= _POSIX_C_SOURCE - 0
#define __USE_POSIX 200809L
#elif 200112L <= _POSIX_C_SOURCE - 0
#define __USE_POSIX 200112L

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2012 Jonas 'Sortie' Termansen.
* Copyright (c) 2012, 2024 Jonas 'Sortie' Termansen.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@ -24,28 +24,23 @@
#include <sys/__/types.h>
#ifdef __cplusplus
extern "C" {
#endif
#ifndef __time_t_defined
#define __time_t_defined
typedef __time_t time_t;
#endif
#ifdef __cplusplus
} /* extern "C" */
#endif
#include <sortix/poll.h>
#if __USE_SORTIX || 202405L <= __USE_POSIX
#include <sortix/sigset.h>
#include <sortix/timespec.h>
#endif
#ifdef __cplusplus
extern "C" {
#endif
int poll(struct pollfd* fds, nfds_t nfds, int timeout);
#if __USE_SORTIX || 202405L <= __USE_POSIX
int ppoll(struct pollfd* fds, nfds_t nfds, const struct timespec* timeout,
const sigset_t* sigmask);
#endif
#ifdef __cplusplus
} /* extern "C" */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011-2017, 2022 Jonas 'Sortie' Termansen.
* Copyright (c) 2011-2017, 2022, 2024 Jonas 'Sortie' Termansen.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@ -121,7 +121,6 @@ int mkstemp(char*);
int mkstemps(char*, int);
int on_exit(void (*function)(int, void*), void* arg);
void qsort(void*, size_t, size_t, int (*)(const void*, const void*));
void qsort_r(void*, size_t, size_t, int (*)(const void*, const void*, void*), void*);
#if !defined(__is_sortix_libc) /* not a warning inside libc */
__attribute__((__warning__("rand() isn't random, use arc4random()")))
#endif
@ -156,6 +155,17 @@ unsigned long long strtoull(const char* __restrict, char** __restrict, int);
long long strtoll(const char* __restrict, char** __restrict, int);
#endif
/* Functions from POSIX 2024. */
#if __USE_SORTIX || 202405L <= __USE_POSIX
void qsort_r(void*, size_t, size_t, int (*)(const void*, const void*, void*), void*);
#ifdef __TRACE_ALLOCATION_SITES
void* reallocarray_trace(struct __allocation_site*, void*, size_t, size_t);
#define reallocarray(a, b, c) reallocarray_trace(ALLOCATION_SITE, (a), (b), (c))
#else
void* reallocarray(void*, size_t, size_t);
#endif
#endif
#if defined(__is_sortix_libc)
struct exit_handler
{
@ -204,12 +214,6 @@ int posix_openpt(int);
uint32_t arc4random(void);
void arc4random_buf(void*, size_t);
uint32_t arc4random_uniform(uint32_t);
#ifdef __TRACE_ALLOCATION_SITES
void* reallocarray_trace(struct __allocation_site*, void*, size_t, size_t);
#define reallocarray(a, b, c) reallocarray_trace(ALLOCATION_SITE, (a), (b), (c))
#else
void* reallocarray(void*, size_t, size_t);
#endif
int ptsname_r(int, char*, size_t);
#endif

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, 2012, 2013, 2014, 2017, 2022 Jonas 'Sortie' Termansen.
* Copyright (c) 2011-2014, 2017, 2022, 2024 Jonas 'Sortie' Termansen.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@ -119,6 +119,12 @@ char* strsignal(int signum);
size_t strxfrm_l(char* __restrict, const char* __restrict, size_t, locale_t);
#endif
/* Functions from POSIX 2024. */
#if __USE_SORTIX || 202405L <= __USE_POSIX
size_t strlcat(char* __restrict, const char* __restrict, size_t);
size_t strlcpy(char* __restrict, const char* __restrict, size_t);
#endif
/* Functions copied from elsewhere. */
#if __USE_SORTIX
void explicit_bzero(void*, size_t);
@ -127,8 +133,6 @@ void* memrchr(const void*, int, size_t);
/* TODO: strcasecmp_l */
char* strchrnul(const char* str, int c);
char* stresep(char**, const char*, int);
size_t strlcat(char* __restrict, const char* __restrict, size_t);
size_t strlcpy(char* __restrict, const char* __restrict, size_t);
/* TODO: strncasecmp_l */
char* strsep(char**, const char*);
int strverscmp(const char*, const char*);

View File

@ -43,10 +43,10 @@ extern "C" {
#define _POSIX_VERSION __USE_POSIX /* C bindings */
#define _POSIX2_VERSION __USE_POSIX /* Shell utilities. */
/* The native API is based on POSIX 2008. */
/* The native API is based on POSIX 2024. */
#elif __USE_SORTIX
#define _POSIX_VERSION 200809L /* C bindings */
#define _POSIX2_VERSION 200809L /* Shell utilities. */
#define _POSIX_VERSION 202405L /* C bindings */
#define _POSIX2_VERSION 202405L /* Shell utilities. */
/* That's odd. This is a POSIX header, but the POSIX API is not visible. The
best option is probably to just say we are the 1990 POSIX standard, since it
@ -67,95 +67,86 @@ extern "C" {
#define _XOPEN_VERSION 4
#endif
/* #define _POSIX_ADVISORY_INFO 200809L
/* #define _POSIX_ADVISORY_INFO 202405L
TODO: Uncomment when posix_fadvise(), posix_fallocate(), posix_madvise(),
posix_memalign() has been added. */
#define _POSIX_ASYNCHRONOUS_IO 200809L
#define _POSIX_BARRIERS 200809L
#define _POSIX_ASYNCHRONOUS_IO 202405L
#define _POSIX_BARRIERS 202405L
/* TODO: _POSIX_CHOWN_RESTRICTED - Decide when security policies are implemented. */
#define _POSIX_CLOCK_SELECTION 200809L
#define _POSIX_CPUTIME 200809L
#define _POSIX_FSYNC 200809L
#define _POSIX_IPV6 200809L
#define _POSIX_JOB_CONTROL
#define _POSIX_CLOCK_SELECTION 202405L
#define _POSIX_CPUTIME 202405L
/* #undef _POSIX_DEVICE_CONTROL - posix_devctl won't be implemented */
#define _POSIX_FSYNC 202405L
#define _POSIX_IPV6 202405L
#define _POSIX_JOB_CONTROL 1
/*TODO: _POSIX_MAPPED_FILES - Needs to be implemented */
/*TODO: _POSIX_MEMLOCK - Research what this is. */
/*TODO: _POSIX_MEMLOCK_RANGE - Research what this is. */
#define _POSIX_MEMORY_PROTECTION 200809L
#define _POSIX_MEMORY_PROTECTION 202405L
/*TODO: _POSIX_MESSAGE_PASSING - Research what this is. */
#define _POSIX_MONOTONIC_CLOCK 200809L
#define _POSIX_MONOTONIC_CLOCK 202405L
#define _POSIX_NO_TRUNC 1
/*TODO: _POSIX_PRIORITIZED_IO - Research what this is. */
/*TODO: _POSIX_PRIORITY_SCHEDULING - Research what this is. */
/*TODO: _POSIX_RAW_SOCKETS - Research what this is. */
#define _POSIX_READER_WRITER_LOCKS 200809L
#define _POSIX_REALTIME_SIGNALS 200809L
/* #define _POSIX_REGEXP 1
TODO: Uncomment when regular expressions are implemented. */
#define _POSIX_READER_WRITER_LOCKS 202405L
#define _POSIX_REALTIME_SIGNALS 202405L
#define _POSIX_REGEXP 1
/* #define _POSIX_SAVED_IDS 1
TODO: Uncomment when saved ids are implemented. I forgot if they already are. */
#define _POSIX_SEMAPHORES 200809L
#define _POSIX_SEMAPHORES 202405L
/*TODO: _POSIX_SHARED_MEMORY_OBJECTS - Research what this is. */
#define _POSIX_SHELL 1
/*TODO: _POSIX_SPAWN - Research what this is. */
#define _POSIX_SPIN_LOCKS 200809L
#define _POSIX_SPIN_LOCKS 202405L
/*TODO: _POSIX_SPORADIC_SERVER - Research what this is. */
/*TODO: _POSIX_SYNCHRONIZED_IO - Research what this is. */
/*TODO: _POSIX_THREAD_ATTR_STACKADDR - Research what this is. */
/*TODO: _POSIX_THREAD_ATTR_STACKSIZE - Research what this is. */
#define _POSIX_THREAD_CPUTIME 200809L
#define _POSIX_THREAD_ATTR_STACKSIZE 202405L
#define _POSIX_THREAD_CPUTIME 202405L
/*TODO: _POSIX_THREAD_PRIO_INHERIT - Research what this is. */
/*TODO: _POSIX_THREAD_PRIO_PROTECT - Research what this is. */
/*TODO: _POSIX_THREAD_PRIORITY_SCHEDULING - Research what this is. */
/*TODO: _POSIX_THREAD_PROCESS_SHARED - Research what this is. */
/*TODO: _POSIX_THREAD_ROBUST_PRIO_INHERIT - Research what this is. */
/*TODO: _POSIX_THREAD_ROBUST_PRIO_PROTECT - Research what this is. */
#define _POSIX_THREAD_SAFE_FUNCTIONS 200809L
#define _POSIX_THREAD_SAFE_FUNCTIONS 202405L
/*TODO: _POSIX_THREAD_SPORADIC_SERVER - Research what this is. */
#define _POSIX_THREADS 200809L
#define _POSIX_TIMEOUTS 200809L
#define _POSIX_TIMERS 200809L
/* TODO: _POSIX_TRACE (Obsolescent) - Research what this is. */
/* TODO: _POSIX_TRACE_EVENT_FILTER (Obsolescent) - Research what this is. */
/* TODO: _POSIX_TRACE_INHERIT (Obsolescent) - Research what this is. */
/* TODO: _POSIX_TRACE_LOG (Obsolescent) - Research what this is. */
/* TODO: TYPED_MEMORY_OBJECTS - Research what this is. */
/* TODO: _POSIX_V6_ILP32_OFF32 (Obsolescent) - Research what this is. */
/* TODO: _POSIX_V6_ILP32_OFFBIG (Obsolescent) - Research what this is. */
/* TODO: _POSIX_V6_LP64_OFF64 (Obsolescent) - Research what this is. */
/* TODO: _POSIX_V6_LPBIG_OFFBIG (Obsolescent) - Research what this is. */
/* TODO: _POSIX_V7_ILP32_OFF32 - Research what this is. */
/* TODO: _POSIX_V7_ILP32_OFFBIG - Research what this is. */
/* TODO: _POSIX_V7_LP64_OFF64 - Research what this is. */
/* TODO: _POSIX_V7_LPBIG_OFFBIG - Research what this is. */
#define _POSIX_THREADS 202405L
#define _POSIX_TIMEOUTS 202405L
#define _POSIX_TIMERS 202405L
/* TODO: _POSIX_TYPED_MEMORY_OBJECTS - Research what this is. */
/* TODO: _POSIX_V7_ILP32_OFF32 (Obsolescent) - Research what this is. */
/* TODO: _POSIX_V7_ILP32_OFFBIG (Obsolescent) - Research what this is. */
/* TODO: _POSIX_V7_LP64_OFF64 (Obsolescent) - Research what this is. */
/* TODO: _POSIX_V7_LPBIG_OFFBIG (Obsolescent) - Research what this is. */
/* TODO: _POSIX_V8_ILP32_OFF32 - Research what this is. */
/* TODO: _POSIX_V8_ILP32_OFFBIG - Research what this is. */
/* TODO: _POSIX_V8_LP64_OFF64 - Research what this is. */
/* TODO: _POSIX_V8_LPBIG_OFFBIG - Research what this is. */
#define _POSIX2_C_BIND _POSIX2_VERSION
#define _POSIX2_C_DEV _POSIX2_VERSION
#define _POSIX2_CHAR_TERM 1
/* TODO: _POSIX2_FORT_RUN - When fortran becomes supported. */
/* #define _POSIX2_LOCALEDEF __POSIX2_THIS_VERSION
/* #define _POSIX2_LOCALEDEF 202405L
TODO: Uncomment when locales are implemented. */
/* TODO: _POSIX2_PBS (Obsolescent) - Research what this is. */
/* TODO: _POSIX2_PBS_ACCOUNTING (Obsolescent) - Research what this is. */
/* TODO: _POSIX2_PBS_CHECKPOINT (Obsolescent) - Research what this is. */
/* TODO: _POSIX2_PBS_LOCATE (Obsolescent) - Research what this is. */
/* TODO: _POSIX2_PBS_MESSAGE (Obsolescent) - Research what this is. */
/* TODO: _POSIX2_PBS_TRACK (Obsolescent) - Research what this is. */
/* TODO: _POSIX2_SW_DEV - Research what this is. (Define to _POSIX2_VERSION) */
/* #define _POSIX2_UPE 200809L
/* TODO: _POSIX2_SW_DEV - Research what this is. */
/* #define _POSIX2_UPE 202405L
TODO: Uncomment when bg, ex, fc, fg, jobs, more, talk, vi are implemented. */
/* TODO: _XOPEN_CRYPT - Research what this is. */
#define _XOPEN_ENH_I18N 1
#define _XOPEN_REALTIME 1
#define _XOPEN_REALTIME 1
/* TODO: _XOPEN_STREAMS (Obsolescent) - Probably don't want to support this. */
#define _XOPEN_REALTIME_THREADS 1
/* TODO: _XOPEN_UNIX - Decide whether we actually support this (probably not),
but also whether this header should lie. */
/* TODO: _XOPEN_UUCP - Research what this is. */
/* TODO: _POSIX_ASYNC_IO - Research what exactly this is. */
/* TODO: _POSIX_FALLOC - Research what exactly this is. */
/* TODO: _POSIX_PRIO_IO - Research what exactly this is. */
/* TODO: _POSIX_SYNC_IO - Research what exactly this is. */
/* TODO: _POSIX_TIMESTAMP_RESOLUTION - Research what exactly this is. */
/* TODO: _POSIX2_SYMLINKS - Research what exactly this is. */
#define _POSIX_TIMESTAMP_RESOLUTION 1
#define _POSIX2_SYMLINKS 1
#ifndef NULL
#define __need_NULL
@ -163,35 +154,35 @@ extern "C" {
#endif
#define _CS_PATH 0
#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS 1
#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS 2
#define _CS_POSIX_V7_ILP32_OFF32_LIBS 3
#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS 4
#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS 5
#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS 6
#define _CS_POSIX_V7_LP64_OFF64_CFLAGS 7
#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS 8
#define _CS_POSIX_V7_LP64_OFF64_LIBS 9
#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS 10
#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS 11
#define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS 12
#define _CS_POSIX_V7_THREADS_CFLAGS 13
#define _CS_POSIX_V7_THREADS_LDFLAGS 14
#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS 15
#define _CS_POSIX_V8_ILP32_OFF32_CFLAGS 1
#define _CS_POSIX_V8_ILP32_OFF32_LDFLAGS 2
#define _CS_POSIX_V8_ILP32_OFF32_LIBS 3
#define _CS_POSIX_V8_ILP32_OFFBIG_CFLAGS 4
#define _CS_POSIX_V8_ILP32_OFFBIG_LDFLAGS 5
#define _CS_POSIX_V8_ILP32_OFFBIG_LIBS 6
#define _CS_POSIX_V8_LP64_OFF64_CFLAGS 7
#define _CS_POSIX_V8_LP64_OFF64_LDFLAGS 8
#define _CS_POSIX_V8_LP64_OFF64_LIBS 9
#define _CS_POSIX_V8_LPBIG_OFFBIG_CFLAGS 10
#define _CS_POSIX_V8_LPBIG_OFFBIG_LDFLAGS 11
#define _CS_POSIX_V8_LPBIG_OFFBIG_LIBS 12
#define _CS_POSIX_V8_THREADS_CFLAGS 13
#define _CS_POSIX_V8_THREADS_LDFLAGS 14
#define _CS_POSIX_V8_WIDTH_RESTRICTED_ENVS 15
#define _CS_V7_ENV 16
#define _CS_POSIX_V6_ILP32_OFF32_CFLAGS 17 /* obsolescent */
#define _CS_POSIX_V6_ILP32_OFF32_LDFLAGS 18 /* obsolescent */
#define _CS_POSIX_V6_ILP32_OFF32_LIBS 19 /* obsolescent */
#define _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS 20 /* obsolescent */
#define _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS 21 /* obsolescent */
#define _CS_POSIX_V6_ILP32_OFFBIG_LIBS 22 /* obsolescent */
#define _CS_POSIX_V6_LP64_OFF64_CFLAGS 23 /* obsolescent */
#define _CS_POSIX_V6_LP64_OFF64_LDFLAGS 24 /* obsolescent */
#define _CS_POSIX_V6_LP64_OFF64_LIBS 25 /* obsolescent */
#define _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS 26 /* obsolescent */
#define _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS 27 /* obsolescent */
#define _CS_POSIX_V6_LPBIG_OFFBIG_LIBS 28 /* obsolescent */
#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS 29 /* obsolescent */
#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS 17 /* obsolescent */
#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS 18 /* obsolescent */
#define _CS_POSIX_V7_ILP32_OFF32_LIBS 19 /* obsolescent */
#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS 20 /* obsolescent */
#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS 21 /* obsolescent */
#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS 22 /* obsolescent */
#define _CS_POSIX_V7_LP64_OFF64_CFLAGS 23 /* obsolescent */
#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS 24 /* obsolescent */
#define _CS_POSIX_V7_LP64_OFF64_LIBS 25 /* obsolescent */
#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS 26 /* obsolescent */
#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS 27 /* obsolescent */
#define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS 28 /* obsolescent */
#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS 29 /* obsolescent */
#define _CS_V6_ENV 30 /* obsolescent */
/* Sortix will not support POSIX advisory locks and doesn't declare:
@ -221,6 +212,8 @@ extern "C" {
#define _PC_SYNC_IO 19
#define _PC_TIMESTAMP_RESOLUTION 20
#define _PC_VDISABLE 21
#define _PC_FALLOC 22
#define _PC_TEXTDOMAIN_MAX 23
#define _SC_AIO_LISTIO_MAX 0
#define _SC_AIO_MAX 1
@ -347,6 +340,9 @@ extern "C" {
#define _SC_XOPEN_UNIX 132
#define _SC_XOPEN_UUCP 133
#define _SC_XOPEN_VERSION 134
#define _SC_NPROCESSORS_CONF 135
#define _SC_NPROCESSORS_ONLN 136
#define _SC_NSIG 137
#define STDIN_FILENO 0
#define STDOUT_FILENO 1
@ -535,6 +531,13 @@ int symlinkat(const char*, int, const char*);
int unlinkat(int, const char*, int);
#endif
/* Functions from POSIX 2024. */
#if __USE_SORTIX || 202405L <= __USE_POSIX
int dup3(int, int, int);
int getentropy(void*, size_t);
int pipe2(int [2], int);
#endif
#if __USE_SORTIX || !(200112L <= __USE_POSIX || 600 <= __USE_XOPEN)
size_t getpagesize(void);
#endif
@ -545,11 +548,8 @@ int chroot(const char*);
int closefrom(int);
int crypt_checkpass(const char*, const char*);
int crypt_newhash(const char*, const char*, char*, size_t);
int dup3(int, int, int);
int execvpe(const char*, char* const [], char* const []);
char* get_current_dir_name(void);
int getentropy(void*, size_t);
int pipe2(int [2], int);
int sethostname(const char*, size_t);
typedef unsigned int useconds_t;
int usleep(useconds_t useconds);

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, 2012, 2013, 2014, 2015 Jonas 'Sortie' Termansen.
* Copyright (c) 2011, 2012, 2013, 2014, 2015, 2024 Jonas 'Sortie' Termansen.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@ -207,6 +207,12 @@ size_t wcsnrtombs(char* __restrict, const wchar_t** __restrict, size_t, size_t,
/* TODO: size_t wcsxfrm_l(wchar_t* __restrict, const wchar_t* __restrict, size_t, locale_t); */
#endif
/* Functions from POSIX 2024. */
#if __USE_SORTIX || 202405L <= __USE_POSIX
size_t wcslcat(wchar_t* __restrict, const wchar_t* __restrict, size_t);
size_t wcslcpy(wchar_t* __restrict, const wchar_t* __restrict, size_t);
#endif
/* Functions copied from elsewhere. */
#if __USE_SORTIX
/* TODO: getwc_unlocked */
@ -219,8 +225,6 @@ size_t wcsnrtombs(char* __restrict, const wchar_t** __restrict, size_t, size_t,
/* TODO: fputws_unlocked */
wchar_t* wcschrnul(const wchar_t*, wchar_t);
/* TODO: wcsftime_l */
size_t wcslcat(wchar_t* __restrict, const wchar_t* __restrict, size_t);
size_t wcslcpy(wchar_t* __restrict, const wchar_t* __restrict, size_t);
/* TODO: wchar_t* wmempcpy(wchar_t* __restrict, const wchar_t* __restrict, size_t); */
/* TODO: wcstod_l? */
/* TODO: wcstof_l? */