Skip to content

Commit

Permalink
pythongh-100530: Change the error message for MatchClass
Browse files Browse the repository at this point in the history
  • Loading branch information
sobolevn committed Apr 16, 2023
1 parent 2b6f5c3 commit 26702d0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Change the error message for ``MatchClass``.
2 changes: 1 addition & 1 deletion Python/ceval.c
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ match_class(PyThreadState *tstate, PyObject *subject, PyObject *type,
Py_ssize_t nargs, PyObject *kwargs)
{
if (!PyType_Check(type)) {
const char *e = "called match pattern must be a type";
const char *e = "called match pattern must be a class";
_PyErr_Format(tstate, PyExc_TypeError, e);
return NULL;
}
Expand Down

0 comments on commit 26702d0

Please sign in to comment.