malat
malat

Reputation: 12502

What's ctypes.c_ssize_t?

I am reading the python3 ctypes documentation and stumble upon:

class ctypes.c_ssize_t
Represents the C ssize_t datatype.

I am surprised to read this, since ssize_t is not defined in C (but POSIX). Is the documentation inaccurate, and instead meant to say ptrdiff_t ?

Upvotes: 0

Views: 152

Answers (1)

MemReflect
MemReflect

Reputation: 551

Issue #6729 (migrated to GitHub as Issue #50978) raised awareness of the lack of ctypes.c_ssize_t, and a patch was added to remedy the missing type, so the answer to your question is no, ptrdiff_t was not intended.

Upvotes: 1

Related Questions