Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on In CPython, types implemented in C are part of the type tree. Parent comment
I'm pretty sure the word "class" here comes from the repr for types, in Objects/typeobject.c :
static PyObject * type_repr(PyTypeObject *type) { ... if (mod != NULL && !_PyUnicode_EqualToASCIIId(mod, &PyId_builtins)) rtn = PyUnicode_FromFormat("<class '%U.%U'>", mod, name); else rtn = PyUnicode_FromFormat("<class '%s'>", type->tp_name); ...
PyTypeObject PyType_Type = { PyVarObject_HEAD_INIT(&PyType_Type, 0) "type", /* tp_name */ ... (reprfunc)type_repr, /* tp_repr */
(I could be wrong - I'm no expert at the Python internals.)
There are no comments on this comment yet.
I'm pretty sure the word "class" here comes from the repr for types, in Objects/typeobject.c :
which is used later on when defining the "type" type: That is, Python 3 has no actual "class" type, so it's not correct to say that '"type" is an instance of "class."'(I could be wrong - I'm no expert at the Python internals.)