[libcxx-commits] [PATCH] D114563: [libc++] Fix ssize test that made an assumption about ptrdiff_t
Martin Storsjö via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Wed Nov 24 13:52:30 PST 2021
mstorsjo added a comment.
> returns a type that is larger than ptrdiff_t,
> where ptrdiff_t is int, but size_t is still unsigned long. As a result, std::ssize returns long
Unless this is a _really_ special platform, isn't long just 32 bits in this setup? I.e. `sizeof(ptrdiff_t) == sizeof(ssize_t)`, (and `sizeof(int) == sizeof(long)`), but the root cause is that `int` and `long` are two distinct different types even if their sizes happen to match?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D114563/new/
https://reviews.llvm.org/D114563
More information about the libcxx-commits
mailing list