代码之家  ›  专栏  ›  技术社区  ›  builder-7000

打印GDB设置值

gdb
  •  0
  • builder-7000  · 技术社区  · 7 年前

    如何打印GDB设置的值?例如,如果我使用命令

    set width 5
    

    后来我想知道 width

    print width
    print &width
    set width?
    

    5 . 任何帮助都将不胜感激。

    1 回复  |  直到 7 年前
        1
  •  1
  •   ks1322    7 年前

    show width .

    (gdb) set width 100
    (gdb) show width 
    Number of characters gdb thinks are in a line is 100.
    
    推荐文章