bits shared by the bytesobject and unicodeobject implementations (andpossibly other modules, in a not too distant future).the stuff in here is included into relevant places; see the individualsource files for details.--------------------------------------------------------------------the following defines used by the different modules:STRINGLIB_CHARthe type used to hold a character (char or Py_UNICODE)STRINGLIB_EMPTYa PyObject representing the empty string, only to be used ifSTRINGLIB_MUTABLE is 0Py_ssize_t STRINGLIB_LEN(PyObject*)returns the length of the given string object (which must be of theright type)PyObject* STRINGLIB_NEW(STRINGLIB_CHAR*, Py_ssize_t)creates a new string objectSTRINGLIB_CHAR* STRINGLIB_STR(PyObject*)returns the pointer to the character data for the given stringobject (which must be of the right type)int STRINGLIB_CHECK_EXACT(PyObject *)returns true if the object is an instance of our type, not a subclassSTRINGLIB_MUTABLEmust be 0 or 1 to tell the cpp macros in stringlib code if the objectbeing operated on is mutable or not
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。