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 Windson Yang
Recipients Windson Yang, mark.dickinson, serhiy.storchaka, sir-sigurd, tim.peters
Date 2018-09-22.02:58:00
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1537585080.18.0.956365154283.issue34397@psf.upfronthosting.co.za>
In-reply-to
Content
Hello, Tim Peters. I wonder why we need to add size_t here:

    assert((size_t)Py_SIZE(a) + (size_t)Py_SIZE(b) <= (size_t)PY_SSIZE_T_MAX);

AFAIK, PY_SSIZE_T_MAX = ((Py_ssize_t)(((size_t)-1)>>1)) which is signed, either Py_SIZE(a) or Py_SIZE(b) is a positive number. Why we need to concast them to size_t, Thank you?
History
Date User Action Args
2018-09-22 02:58:00Windson Yangsetrecipients: + Windson Yang, tim.peters, mark.dickinson, serhiy.storchaka, sir-sigurd
2018-09-22 02:58:00Windson Yangsetmessageid: <1537585080.18.0.956365154283.issue34397@psf.upfronthosting.co.za>
2018-09-22 02:58:00Windson Yanglinkissue34397 messages
2018-09-22 02:58:00Windson Yangcreate