mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-04-30 03:40:34 +02:00
(Sample GDB Initialization File): New section.
This commit is contained in:
parent
569c483b32
commit
3cc0883ec0
1 changed files with 44 additions and 0 deletions
44
HACKING
44
HACKING
|
@ -70,6 +70,50 @@ You are lost in a little maze of automatically generated files, all
|
||||||
different.
|
different.
|
||||||
|
|
||||||
|
|
||||||
|
Sample GDB Initialization File=========================================
|
||||||
|
|
||||||
|
Here is a sample .gdbinit posted by Bill Schottstaedt (modified to
|
||||||
|
use `set' instead of `call' in some places):
|
||||||
|
|
||||||
|
define gp
|
||||||
|
set gdb_print($arg0)
|
||||||
|
print gdb_output
|
||||||
|
end
|
||||||
|
document gp
|
||||||
|
Executes (object->string arg)
|
||||||
|
end
|
||||||
|
|
||||||
|
define ge
|
||||||
|
call gdb_read($arg0)
|
||||||
|
call gdb_eval(gdb_result)
|
||||||
|
set gdb_print(gdb_result)
|
||||||
|
print gdb_output
|
||||||
|
end
|
||||||
|
document ge
|
||||||
|
Executes (print (eval (read arg))): ge "(+ 1 2)" => 3
|
||||||
|
end
|
||||||
|
|
||||||
|
define gh
|
||||||
|
call g_help(scm_str2symbol($arg0), 20)
|
||||||
|
set gdb_print($1)
|
||||||
|
print gdb_output
|
||||||
|
end
|
||||||
|
document gh
|
||||||
|
Prints help string for arg: gh "enved-target"
|
||||||
|
end
|
||||||
|
|
||||||
|
Bill further writes:
|
||||||
|
|
||||||
|
so in gdb if you see something useless like:
|
||||||
|
|
||||||
|
#32 0x081ae8f4 in scm_primitive_load (filename=1112137128) at load.c:129
|
||||||
|
|
||||||
|
You can get the file name with gp:
|
||||||
|
|
||||||
|
(gdb) gp 1112137128
|
||||||
|
$1 = 0x40853fac "\"/home/bil/test/share/guile/1.5.0/ice-9/session.scm\""
|
||||||
|
|
||||||
|
|
||||||
Contributing Your Changes ============================================
|
Contributing Your Changes ============================================
|
||||||
|
|
||||||
- If you have put together a change that meets the coding standards
|
- If you have put together a change that meets the coding standards
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue