This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients christian.heimes, hroncok, petr.viktorin, vstinner
Date 2022-01-25.19:13:02
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1643137982.46.0.615388642196.issue46513@roundup.psfhosted.org>
In-reply-to
Content
To test if a C type is signed or not, I wrote this macro:

// Test if a C type is signed.
//
// Usage: assert(_Py_CTYPE_IS_SIGNED(char)); // fail if 'char' type is unsigned
#define _Py_CTYPE_IS_SIGNED(T) (((T)-1) < 0)

I planned to use it to raise an error on "import audioop" if the C "char" type is unsigned, but it seems like it's not needed, since the C extensions seems to work if char is signed or unsigned (I only read the C code, I didn't run test_audioop to actually test it).
History
Date User Action Args
2022-01-25 19:13:02vstinnersetrecipients: + vstinner, christian.heimes, petr.viktorin, hroncok
2022-01-25 19:13:02vstinnersetmessageid: <1643137982.46.0.615388642196.issue46513@roundup.psfhosted.org>
2022-01-25 19:13:02vstinnerlinkissue46513 messages
2022-01-25 19:13:02vstinnercreate