Skip to content

Conversation

@Prabhuk
Copy link

@Prabhuk Prabhuk commented Dec 29, 2025

Remove platform specific headers which were included for ssize_t and use intptr_t instead to prevent failures in baremetal builds.

This patch removes dependency on platform specific headers.
@Prabhuk Prabhuk changed the title Use LLVM libc ssize_t.h Use a portable isize definition. Dec 29, 2025
Copy link
Owner

@dtolnay dtolnay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you have an idea how to preserve this assertion in the cases that ssize_t is available?

cxx/src/cxx.cc

Lines 445 to 448 in cd508fc

static_assert(sizeof(rust::isize) == sizeof(std::intptr_t),
"unsupported ssize_t size");
static_assert(alignof(rust::isize) == alignof(std::intptr_t),
"unsupported ssize_t alignment");

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants