mirror of
https://github.com/python/cpython.git
synced 2025-08-31 05:58:33 +00:00
Ensure that code object names (co_name) are unicode.
Verify that they print properly too.
This commit is contained in:
parent
a5d16a3f85
commit
41103bf6f2
2 changed files with 11 additions and 6 deletions
|
@ -2991,7 +2991,7 @@ compiler_dictcomp(struct compiler *c, expr_ty e)
|
|||
{
|
||||
static identifier name;
|
||||
if (!name) {
|
||||
name = PyString_FromString("<dictcomp>");
|
||||
name = PyUnicode_FromString("<dictcomp>");
|
||||
if (!name)
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue