Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f903f00 commit bdbb395Copy full SHA for bdbb395
1 file changed
Python/compile.c
@@ -2972,7 +2972,8 @@ expr_constant(expr_ty e)
2972
return PyObject_IsTrue(e->v.Str.s);
2973
case Name_kind:
2974
/* optimize away names that can't be reassigned */
2975
- id = _PyUnicode_AsDefaultEncodedString(e->v.Name.id, NULL);
+ id = PyString_AS_STRING(
2976
+ _PyUnicode_AsDefaultEncodedString(e->v.Name.id, NULL));
2977
if (strcmp(id, "True") == 0) return 1;
2978
if (strcmp(id, "False") == 0) return 0;
2979
if (strcmp(id, "None") == 0) return 0;
0 commit comments