mirror of
https://github.com/python/cpython.git
synced 2025-08-31 14:07:50 +00:00
bpo-35132: Fixes missing target in gdb pep0393 check. (GH-11848)
This commit is contained in:
parent
d9bd8ec2a4
commit
1ceb3a3d17
2 changed files with 2 additions and 1 deletions
|
@ -0,0 +1 @@
|
||||||
|
Fix py-list and py-bt commands of python-gdb.py on gdb7.
|
|
@ -1178,7 +1178,7 @@ class PyUnicodeObjectPtr(PyObjectPtr):
|
||||||
def proxyval(self, visited):
|
def proxyval(self, visited):
|
||||||
global _is_pep393
|
global _is_pep393
|
||||||
if _is_pep393 is None:
|
if _is_pep393 is None:
|
||||||
fields = gdb.lookup_type('PyUnicodeObject').target().fields()
|
fields = gdb.lookup_type('PyUnicodeObject').fields()
|
||||||
_is_pep393 = 'data' in [f.name for f in fields]
|
_is_pep393 = 'data' in [f.name for f in fields]
|
||||||
if _is_pep393:
|
if _is_pep393:
|
||||||
# Python 3.3 and newer
|
# Python 3.3 and newer
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue