diff options
| author | Kim F. Storm | 2004-11-03 12:49:39 +0000 |
|---|---|---|
| committer | Kim F. Storm | 2004-11-03 12:49:39 +0000 |
| commit | decf4020140d26df76dfb02ae7e032c07ac159c2 (patch) | |
| tree | 5c3c4a881900495bc1ed1d7fd0d5bac4b50348c3 | |
| parent | c524d9a6daae2632b41c726919c8a4b78ce91e35 (diff) | |
| download | emacs-decf4020140d26df76dfb02ae7e032c07ac159c2.tar.gz emacs-decf4020140d26df76dfb02ae7e032c07ac159c2.zip | |
(ppt): New function.
| -rw-r--r-- | src/.gdbinit | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/.gdbinit b/src/.gdbinit index 1bcb9f6789b..6adb9f3fa02 100644 --- a/src/.gdbinit +++ b/src/.gdbinit | |||
| @@ -70,6 +70,34 @@ Print the argument as an emacs s-expression | |||
| 70 | Works only when an inferior emacs is executing. | 70 | Works only when an inferior emacs is executing. |
| 71 | end | 71 | end |
| 72 | 72 | ||
| 73 | # Print out current buffer point and boundaries | ||
| 74 | define ppt | ||
| 75 | set $b = current_buffer | ||
| 76 | set $t = $b->text | ||
| 77 | printf "BUF PT: %d", $b->pt | ||
| 78 | if ($b->pt != $b->pt_byte) | ||
| 79 | printf "[%d]", $b->pt_byte | ||
| 80 | end | ||
| 81 | printf " of 1..%d", $t->z | ||
| 82 | if ($t->z != $t->z_byte) | ||
| 83 | printf "[%d]", $t->z_byte | ||
| 84 | end | ||
| 85 | if ($b->begv != 1 || $b->zv != $t->z) | ||
| 86 | printf " NARROW=%d..%d", $b->begv, $b->zv | ||
| 87 | if ($b->begv != $b->begv_byte || $b->zv != $b->zv_byte) | ||
| 88 | printf " [%d..%d]", $b->begv_byte, $b->zv_byte | ||
| 89 | end | ||
| 90 | end | ||
| 91 | printf " GAP: %d", $t->gpt | ||
| 92 | if ($t->gpt != $t->gpt_byte) | ||
| 93 | printf "[%d]", $t->gpt_byte | ||
| 94 | end | ||
| 95 | printf " SZ=%d\n", $t->gap_size | ||
| 96 | end | ||
| 97 | document ppt | ||
| 98 | Print point, beg, end, narrow, and gap for current buffer. | ||
| 99 | end | ||
| 100 | |||
| 73 | define xtype | 101 | define xtype |
| 74 | xgettype $ | 102 | xgettype $ |
| 75 | output $type | 103 | output $type |