Mercurial > cpython-lru_cache-weakref
diff Include/stringobject.h @ 23542:220b98f06415 legacy-trunk
- A new type object, 'string', is added. This is a common base type
for 'str' and 'unicode', and can be used instead of
types.StringTypes, e.g. to test whether something is "a string":
isinstance(x, string) is True for Unicode and 8-bit strings. This
is an abstract base class and cannot be instantiated directly.
| author | Guido van Rossum <guido@python.org> |
|---|---|
| date | Fri, 24 May 2002 19:01:59 +0000 |
| parents | f3a416b178c4 |
| children | c1eb668525e1 |
line wrap: on
line diff
--- a/Include/stringobject.h Fri May 24 18:47:47 2002 +0000 +++ b/Include/stringobject.h Fri May 24 19:01:59 2002 +0000 @@ -39,6 +39,7 @@ char ob_sval[1]; } PyStringObject; +extern DL_IMPORT(PyTypeObject) PyBaseString_Type; extern DL_IMPORT(PyTypeObject) PyString_Type; #define PyString_Check(op) PyObject_TypeCheck(op, &PyString_Type)
