annotate src/.gdbinit @ 1409:7fd1c810daca

* dispextern.h: New element of frame structure `max_ascent'. Removed elements `nruns' and `face_list'. LINE_HEIGHT and LINE_WIDTH macros removed. New struct face with associated typedef FACE declared, along with accessing macros.
author Joseph Arceneaux <jla@gnu.org>
date Wed, 14 Oct 1992 23:00:18 +0000
parents 0ffcf74fb8ad
children 1f7d20c707c0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
1 # Set up something to print out s-expressions.
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
2 define pr
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
3 set Fprin1 ($, Qexternal_debugging_output)
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
4 echo \n
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
5 end
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
6 document pr
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
7 Print the emacs s-expression which is $.
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
8 Works only when an inferior emacs is executing.
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
9 end
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
10
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
11 # Set this to the same thing as the DATA_SEG_BITS macro in your
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
12 # machine-description files.
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
13 set $data_seg_bits = 0
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
14
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
15 define xtype
999
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
16 output (enum Lisp_Type) (($ >> 24) & 0x7f)
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
17 echo \n
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
18 end
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
19 document xtype
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
20 Print the type of $, assuming it is an Elisp value.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
21 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
22
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
23 define xint
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
24 print (($ & 0x00ffffff) << 8) >> 8
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
25 end
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
26 document xint
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
27 Print $, assuming it is an Elisp integer. This gets the sign right.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
28 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
29
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
30 define xptr
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
31 print (void *) (($ & 0x00ffffff) | $data_seg_bits)
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
32 end
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
33 document xptr
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
34 Print the pointer portion of $, assuming it is an Elisp value.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
35 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
36
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
37 define xwindow
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
38 print (struct window *) (($ & 0x00ffffff) | $data_seg_bits)
999
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
39 printf "%dx%d+%d+%d\n", $->width, $->height, $->left, $->top
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
40 end
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
41 document xwindow
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
42 Print $ as a window pointer, assuming it is an Elisp window value.
999
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
43 Print the window's position as "WIDTHxHEIGHT+LEFT+TOP".
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
44 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
45
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
46 define xmarker
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
47 print (struct Lisp_Marker *) (($ & 0x00ffffff) | $data_seg_bits)
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
48 end
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
49 document xmarker
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
50 Print $ as a marker pointer, assuming it is an Elisp marker value.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
51 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
52
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
53 define xbuffer
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
54 print (struct buffer *) (($ & 0x00ffffff) | $data_seg_bits)
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
55 output &((struct Lisp_String *) ((($->name) & 0x00ffffff) | $data_seg_bits))->data
999
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
56 echo \n
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
57 end
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
58 document xbuffer
727
540b047ece4d *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 648
diff changeset
59 Set $ as a buffer pointer, assuming it is an Elisp buffer value.
540b047ece4d *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 648
diff changeset
60 Print the name of the buffer.
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
61 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
62
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
63 define xsymbol
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
64 print (struct Lisp_Symbol *) (($ & 0x00ffffff) | $data_seg_bits)
999
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
65 output &$->name->data
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
66 echo \n
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
67 end
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
68 document xsymbol
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
69 Print the name and address of the symbol $.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
70 This command assumes that $ is an Elisp symbol value.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
71 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
72
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
73 define xstring
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
74 print (struct Lisp_String *) (($ & 0x00ffffff) | $data_seg_bits)
999
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
75 output ($->size > 10000) ? "big string" : ($->data[0])@($->size)
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
76 echo \n
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
77 end
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
78 document xstring
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
79 Print the contents and address of the string $.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
80 This command assumes that $ is an Elisp string value.
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
81 end
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
82
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
83 define xvector
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
84 print (struct Lisp_Vector *) (($ & 0x00ffffff) | $data_seg_bits)
999
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
85 output ($->size > 1000) ? "big vector" : ($->contents[0])@($->size)
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
86 echo \n
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
87 end
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
88 document xvector
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
89 Print the contents and address of the vector $.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
90 This command assumes that $ is an Elisp vector value.
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
91 end
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
92
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
93 define xframe
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
94 print (struct frame *) (($ & 0x00ffffff) | $data_seg_bits)
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
95 end
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
96 document xframe
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
97 Print $ as a frame pointer, assuming it is an Elisp frame value.
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
98 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
99
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
100 define xcons
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
101 print (struct Lisp_Cons *) (($ & 0x00ffffff) | $data_seg_bits)
1069
ee559fe0f1ab *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 1039
diff changeset
102 output *$
999
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
103 echo \n
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
104 end
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
105 document xcons
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
106 Print the contents of $, assuming it is an Elisp cons.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
107 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
108
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
109 define xcar
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
110 print ((($ >> 24) & 0x7f) == Lisp_Cons ? ((struct Lisp_Cons *) (($ & 0x00ffffff) | $data_seg_bits))->car : 0)
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
111 end
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
112 document xcar
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
113 Print the car of $, assuming it is an Elisp pair.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
114 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
115
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
116 define xcdr
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
117 print ((($ >> 24) & 0x7f) == Lisp_Cons ? ((struct Lisp_Cons *) (($ & 0x00ffffff) | $data_seg_bits))->cdr : 0)
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
118 end
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
119 document xcdr
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
120 Print the cdr of $, assuming it is an Elisp pair.
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
121 end
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
122
1113
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
123 define xsubr
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
124 print (struct Lisp_Subr *) (($ & 0x00ffffff) | $data_seg_bits)
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
125 output *$
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
126 echo \n
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
127 end
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
128 document xsubr
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
129 Print the address of the subr which the Lisp_Object $ points to.
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
130 end
0ffcf74fb8ad entered into RCS
Jim Blandy <jimb@redhat.com>
parents: 1069
diff changeset
131
638
40b255f55df3 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 567
diff changeset
132 set print pretty on
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
133
732
a8d94735277e *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 727
diff changeset
134 unset environment TERMCAP
a8d94735277e *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 727
diff changeset
135 unset environment TERM
999
d8d503897aa5 *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 949
diff changeset
136 echo TERMCAP and TERM environment variables unset.\n
732
a8d94735277e *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 727
diff changeset
137 show environment DISPLAY
a8d94735277e *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 727
diff changeset
138 set args -q
a8d94735277e *** empty log message ***
Jim Blandy <jimb@redhat.com>
parents: 727
diff changeset
139
567
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
140 # Don't let abort actually run, as it will make
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
141 # stdio stop working and therefore the `pr' command below as well.
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
142 break abort
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
143
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
144 # If we are running in synchronous mode, we want a chance to look around
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
145 # before Emacs exits. Perhaps we should put the break somewhere else
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
146 # instead...
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
147 break _XPrintDefaultError
696d82e36360 Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
148