From 7a041162468b83f6cad667b78ed5c786286aed2b Mon Sep 17 00:00:00 2001 From: Pablo Galindo Date: Mon, 19 Apr 2021 23:35:53 +0100 Subject: bpo-25460: Surround suggestions by quotes (GH-25473) --- Python/pythonrun.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Python/pythonrun.c') diff --git a/Python/pythonrun.c b/Python/pythonrun.c index 6f84cab702e..8bd31348b26 100644 --- a/Python/pythonrun.c +++ b/Python/pythonrun.c @@ -956,10 +956,10 @@ print_exception(PyObject *f, PyObject *value) PyObject* suggestions = _Py_Offer_Suggestions(value); if (suggestions) { // Add a trailer ". Did you mean: (...)?" - err = PyFile_WriteString(". Did you mean: ", f); + err = PyFile_WriteString(". Did you mean: '", f); if (err == 0) { err = PyFile_WriteObject(suggestions, f, Py_PRINT_RAW); - err += PyFile_WriteString("?", f); + err += PyFile_WriteString("'?", f); } Py_DECREF(suggestions); } else if (PyErr_Occurred()) { -- cgit v1.2.3