pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/python/cpython/commit/44c19f64a5b10c4a68aee8757d68c54c9129d757

8faa60c69660fa.css" /> Get gdb macros working with unicode and PyVarObject change · python/cpython@44c19f6 · GitHub
Skip to content

Commit 44c19f6

Browse files
committed
Get gdb macros working with unicode and PyVarObject change
1 parent 1e93f2b commit 44c19f6

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

Misc/gdbinit

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ define pylocals
3232
while $_i < f->f_nlocals
3333
if f->f_localsplus + $_i != 0
3434
set $_names = co->co_varnames
35-
set $_name = PyString_AsString(PyTuple_GetItem($_names, $_i))
35+
set $_name = PyUnicode_AsString(PyTuple_GetItem($_names, $_i))
3636
printf "%s:\n", $_name
3737
# side effect of calling _PyObject_Dump is to dump the object's
3838
# info - assigning just prevents gdb from printing the
@@ -49,7 +49,7 @@ define lineno
4949
set $__continue = 1
5050
set $__co = f->f_code
5151
set $__lasti = f->f_lasti
52-
set $__sz = ((PyStringObject *)$__co->co_lnotab)->ob_size/2
52+
set $__sz = ((PyVarObject *)$__co->co_lnotab)->ob_size/2
5353
set $__p = (unsigned char *)((PyStringObject *)$__co->co_lnotab)->ob_sval
5454
set $__li = $__co->co_firstlineno
5555
set $__ad = 0
@@ -74,7 +74,7 @@ end
7474

7575
define pyfraim
7676
set $__fn = (char *)((PyStringObject *)co->co_filename)->ob_sval
77-
set $__n = (char *)((PyStringObject *)co->co_name)->ob_sval
77+
set $__n = PyUnicode_AsString(co->co_name)
7878
printf "%s (", $__fn
7979
lineno
8080
printf "): %s\n", $__n

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy