Skip to content

Commit efa4f6c

Browse files
expose NoExtraItems via _typing
1 parent 4af9d37 commit efa4f6c

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

Include/internal/pycore_typevarobject.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ extern int _Py_typing_type_repr(PyUnicodeWriter *, PyObject *);
2121
extern PyTypeObject _PyTypeAlias_Type;
2222
extern PyTypeObject _PyNoDefault_Type;
2323
extern PyObject _Py_NoDefaultStruct;
24+
extern PyTypeObject _PyNoExtraItems_Type;
25+
extern PyObject _Py_NoExtraItemsStruct;
2426

2527
#ifdef __cplusplus
2628
}

Modules/_typingmodule.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,9 @@ _typing_exec(PyObject *m)
7070
if (PyModule_AddObjectRef(m, "NoDefault", (PyObject *)&_Py_NoDefaultStruct) < 0) {
7171
return -1;
7272
}
73+
if (PyModule_AddObjectRef(m, "NoExtraItems", (PyObject *)&_Py_NoExtraItemsStruct) < 0) {
74+
return -1;
75+
}
7376
return 0;
7477
}
7578

0 commit comments

Comments
 (0)