I noticed that the cwchar and cwctype headers in libc++ are doing more work than I expected them to. In particular:
- cwchar aliases ::FILE into std.
- cwchar includes cwctype
- cwctype includes cctype
I have a C library whose wchar.h does not declare FILE, which AFAICT is C-conforming. Consequently, a user’s source file that includes cwchar doesn’t compile. The POSIX standard specifies that wchar.h declares FILE as an extension to ISO C, but libc++'s headers don’t generally include the POSIX extensions into std.
Is there a libc++ bug here?