Commit graph

4 commits

Author SHA1 Message Date
Elliott Hughes
b266f6522f Add LINE_MAX.
LINE_MAX is a bad idea from the 1970s that we've ignored until now,
but there's already one hack in the AOSP tree (external/ltp) to work
around its absence, and kselftests would need another. Both uses are
bad code, but bad code exists, and iOS/macOS and musl/glibc all have
the same 2048 value, and it is in POSIX, so at least it's consistent
idiocy. Hopefully we're not encouraging more of it!

Bug: https://github.com/llvm/llvm-project/issues/88119
Change-Id: Ief219c3fe20b3d95da7040c4b9411f997b1c0470
2024-04-09 15:41:10 +00:00
Elliott Hughes
dc8a612bf3 Fix WORD_BIT test.
The only explanation for this and the unistd_test failures is that I
wasn't actually running the code I thought I was. There are some unrelated
netdb_test failures still to come...

Bug: N/A
Test: ran tests
Change-Id: I91af9d2d6a42f5433fa27e7cd8f5b903e1af36ba
2017-10-23 12:06:30 -07:00
Elliott Hughes
19d7685982 More <limits.h> fixes.
Went through the POSIX spec for the _POSIX* and _XOPEN* constants.

Bug: http://b/32776472
Test: ran tests
Change-Id: I389100dbc7de354eae9056e44b0a7fa8c37374e3
2017-10-18 13:27:01 -07:00
Elliott Hughes
45da326324 Add tests for all C11 headers.
Well, all except <threads.h> which we have no current plans to implement.

The only thing this turned up is that clang's <float.h> doesn't define
FLT_HAS_SUBNORM/DBL_HAS_SUBNORM/LDBL_HAS_SUBNORM, so for now we assert
that those are missing so that when we get a fixed clang, we notice.

Also the <tgmath.h> is utterly perfunctory, but seems like an appropriate
amount of effort to put in.

Bug: N/A
Test: ran tests
Change-Id: I7f7a7040b3271ceda625bee8a40a9d8cef52ee44
2017-08-29 15:32:18 -07:00