annotate etc/dbxrc.in @ 5176:8b2f75cecb89

rename objects* (.c, .h and .el files) to fontcolor* -------------------- ChangeLog entries follow: -------------------- etc/ChangeLog addition: 2010-02-22 Ben Wing <ben@xemacs.org> * dbxrc.in: Rename objects.c -> fontcolor.c. lisp/ChangeLog addition: 2010-02-22 Ben Wing <ben@xemacs.org> * dumped-lisp.el (preloaded-file-list): * font.el (font-tty-find-closest-color): * fontcolor.el: * fontcolor.el (ws-object-property-1): Removed. * fontcolor.el (fontcolor-property-1): New. * fontcolor.el (font-name): * fontcolor.el (font-ascent): * fontcolor.el (font-descent): * fontcolor.el (font-width): * fontcolor.el (font-height): * fontcolor.el (font-proportional-p): * fontcolor.el (font-properties): * fontcolor.el (font-truename): * fontcolor.el (color-name): * fontcolor.el (color-rgb-components): * x-faces.el: Rename objects.el -> fontcolor.el. lwlib/ChangeLog addition: 2010-02-22 Ben Wing <ben@xemacs.org> * lwlib-colors.h: objects*.h -> fontcolor*.h. man/ChangeLog addition: 2010-02-22 Ben Wing <ben@xemacs.org> * internals/internals.texi (A Summary of the Various XEmacs Modules): * internals/internals.texi (Modules for other Display-Related Lisp Objects): objects*.[ch] -> fontcolor*.[ch]. nt/ChangeLog addition: 2010-02-22 Ben Wing <ben@xemacs.org> * xemacs.dsp: * xemacs.mak: * xemacs.mak (OPT_OBJS): objects*.[ch] -> fontcolor*.[ch]. src/ChangeLog addition: 2010-02-22 Ben Wing <ben@xemacs.org> * EmacsFrame.c: * Makefile.in.in (x_objs): * Makefile.in.in (mswindows_objs): * Makefile.in.in (tty_objs): * Makefile.in.in (gtk_objs): * Makefile.in.in (objs): * console-tty.h: * console-x-impl.h: * console-x-impl.h (struct x_device): * console-x.h: * console-xlike-inc.h: * depend: * device-gtk.c: * device-msw.c: * device-x.c: * device-x.c (x_init_device): * device-x.c (x_finish_init_device): * device.c: * devslots.h (MARKED_SLOT): * emacs.c (main_1): * event-Xt.c: * event-gtk.c: * event-msw.c: * faces.c: * font-mgr.c: * fontcolor-gtk-impl.h: * fontcolor-gtk.c: * fontcolor-gtk.c (syms_of_fontcolor_gtk): * fontcolor-gtk.c (console_type_create_fontcolor_gtk): * fontcolor-gtk.c (vars_of_fontcolor_gtk): * fontcolor-gtk.h: * fontcolor-impl.h: * fontcolor-msw-impl.h: * fontcolor-msw.c: * fontcolor-msw.c (syms_of_fontcolor_mswindows): * fontcolor-msw.c (console_type_create_fontcolor_mswindows): * fontcolor-msw.c (reinit_vars_of_fontcolor_mswindows): * fontcolor-msw.c (vars_of_fontcolor_mswindows): * fontcolor-msw.h: * fontcolor-msw.h (mswindows_color_to_string): * fontcolor-tty-impl.h: * fontcolor-tty.c: * fontcolor-tty.c (syms_of_fontcolor_tty): * fontcolor-tty.c (console_type_create_fontcolor_tty): * fontcolor-tty.c (vars_of_fontcolor_tty): * fontcolor-tty.h: * fontcolor-x-impl.h: * fontcolor-x.c: * fontcolor-x.c (syms_of_fontcolor_x): * fontcolor-x.c (console_type_create_fontcolor_x): * fontcolor-x.c (vars_of_fontcolor_x): * fontcolor-x.c (Xatoms_of_fontcolor_x): * fontcolor-x.h: * fontcolor.c: * fontcolor.c (syms_of_fontcolor): * fontcolor.c (specifier_type_create_fontcolor): * fontcolor.c (reinit_specifier_type_create_fontcolor): * fontcolor.c (reinit_vars_of_fontcolor): * fontcolor.c (vars_of_fontcolor): * fontcolor.h: * fontcolor.h (set_face_boolean_attached_to): * frame-gtk.c: * frame-x.c: * glyphs-eimage.c: * glyphs-gtk.c: * glyphs-msw.c: * glyphs-widget.c: * glyphs-x.c: * glyphs.c: * gtk-glue.c: * gtk-glue.c (xemacs_type_register): * gtk-xemacs.c: * inline.c: * intl-win32.c: * lisp.h: * lrecord.h: * mule-charset.c: * native-gtk-toolbar.c: * redisplay-msw.c: * redisplay-tty.c: * redisplay.c: * select-x.c: * select.c: * symsinit.h: * toolbar-msw.c: * toolbar-msw.c (TOOLBAR_ITEM_ID_BITS): * toolbar-x.c: * ui-gtk.c: * window.c: Rename objects*.[ch] -> fontcolor*.[ch]. Fix up all references to the old files (e.g. in #include statements, Makefiles, functions like syms_of_objects_x(), etc.). tests/ChangeLog addition: 2010-02-22 Ben Wing <ben@xemacs.org> * reproduce-crashes.el (8): objects*.[ch] -> fontcolor*.[ch].
author Ben Wing <ben@xemacs.org>
date Mon, 22 Feb 2010 06:49:30 -0600
parents a1e20876b806
children b785049378e3
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3418
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
1 ## dbx init file for XEmacs -*- ksh -*-
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
2 ## This is the source file for src/.dbxrc. Edit it, and rerun configure.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
3 ## (Running config.status is not enough.)
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
4 ## The generated file depends on src/config.h (currently only in one place).
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
5
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
6 ## Copyright (C) 1998 Free Software Foundation, Inc.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
7
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
8 ## This file is part of XEmacs.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
9
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
10 ## XEmacs is free software; you can redistribute it and/or modify it
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
11 ## under the terms of the GNU General Public License as published by the
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
12 ## Free Software Foundation; either version 2, or (at your option) any
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
13 ## later version.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
14
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
15 ## XEmacs is distributed in the hope that it will be useful, but WITHOUT
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
16 ## ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
17 ## FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
18 ## for more details.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
19
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
20 ## You should have received a copy of the GNU General Public License
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
21 ## along with XEmacs; see the file COPYING. If not, write to
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
22 ## the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
23 ## Boston, MA 02110-1301 USA
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
24
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
25 ## Author: Martin Buchholz
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
26
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
27 ## Other contributors you could ask for help: Ivan Golubev, Jerry James,
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
28 ## Stephen Turnbull.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
29
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
30 ## You can use this file to debug XEmacs using Sun WorkShop's dbx.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
31
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
32 ## Some functions defined here require a running process, but most
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
33 ## don't. Considerable effort has been expended to this end.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
34
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
35 ## Since this file is called `.dbxrc', it will be read by dbx
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
36 ## automatically when dbx is run in the build directory, which is where
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
37 ## developers usually debug their xemacs.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
38
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
39 ## See also the comments in .gdbinit.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
40
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
41 ## See also the question of the XEmacs FAQ, titled
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
42 ## "How to Debug an XEmacs problem with a debugger".
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
43
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
44 ## gdb sources the ./.gdbinit in _addition_ to ~/.gdbinit.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
45 ## But dbx does _not_ source ~/.dbxrc if it found ./.dbxrc.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
46 ## So we simulate the gdb algorithm by doing it ourselves here.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
47
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
48 #define NOT_C_CODE
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
49 #include "config.h"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
50
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
51 if test -r $HOME/.dbxrc; then . $HOME/.dbxrc; fi
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
52
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
53 dbxenv language_mode ansic
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
54
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
55 ignore POLL
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
56 ignore IO
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
57
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
58 #ifdef VDB_POSIX
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
59 ignore SIGSEGV
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
60 ignore SIGBUS
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
61 #endif
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
62
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
63 document lbt << 'end'
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
64 Usage: lbt
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
65 Print the current Lisp stack trace.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
66 Requires a running xemacs process.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
67 end
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
68
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
69 function lbt {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
70 call debug_backtrace()
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
71 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
72
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
73 document ldp << 'end'
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
74 Usage: ldp lisp_object
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
75 Print a Lisp Object value using the Lisp printer.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
76 Requires a running xemacs process.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
77 end
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
78
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
79 function ldp {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
80 call debug_print ($1);
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
81 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
82
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
83 Lisp_Type_Int=-2
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
84
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
85 ## A bug in dbx prevents string variables from having values beginning with `-'!!
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
86 function XEmacsInit {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
87 function ToInt { eval "$1=\$[(int) \`alloc.c\`$1]"; }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
88 ToInt dbg_USE_UNION_TYPE
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
89 ToInt Lisp_Type_Char
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
90 ToInt Lisp_Type_Record
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
91 ToInt dbg_valbits
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
92 ToInt dbg_gctypebits
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
93 function ToLong { eval "$1=\$[(\`alloc.c\`unsigned long) \`alloc.c\`$1]"; }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
94 ToLong dbg_valmask
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
95 ToLong dbg_typemask
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
96 xemacs_initted=yes
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
97 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
98
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
99 function printvar {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
100 for i in $*; do eval "echo $i=\$$i"; done
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
101 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
102
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
103 document decode_object << 'end'
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
104 Usage: decode_object lisp_object
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
105 Extract implementation information from a Lisp Object.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
106 Defines variables $val, $type and $imp.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
107 end
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
108
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
109 ## Various dbx bugs cause ugliness in following code
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
110 function decode_object {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
111 if test -z "$xemacs_initted"; then XEmacsInit; fi;
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
112 if test $dbg_USE_UNION_TYPE = 1; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
113 ## Repeat after me... dbx sux, dbx sux, dbx sux...
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
114 ## Allow both `pobj Qnil' and `pobj 0x82746834' to work
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
115 case $(whatis $1) in
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
116 *Lisp_Object*) obj="$[(`alloc.c`unsigned long)(($1).i)]";;
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
117 *) obj="$[(`alloc.c`unsigned long)($1)]";;
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
118 esac
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
119 else
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
120 obj="$[(`alloc.c`unsigned long)($1)]";
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
121 fi
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
122 if test $[(int)($obj & 1)] = 1; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
123 ## It's an int
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
124 val=$[(long)(((unsigned long long)$obj) >> 1)]
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
125 type=$Lisp_Type_Int
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
126 else
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
127 type=$[(int)(((void*)$obj) & $dbg_typemask)]
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
128 if test $type = $Lisp_Type_Char; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
129 val=$[(void*)(long)(((unsigned long long)($obj & $dbg_valmask)) >> $dbg_gctypebits)]
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
130 else
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
131 ## It's a record pointer
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
132 val=$[(void*)$obj]
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
133 if test "$val" = "(nil)"; then type=null_pointer; fi
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
134 fi
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
135 fi
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
136
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
137 if test $type = $Lisp_Type_Record; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
138 lheader="((struct lrecord_header *) $val)"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
139 lrecord_type=$[(enum lrecord_type) $lheader->type]
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
140 imp=$[(void*)(`alloc.c`lrecord_implementations_table[$lheader->type])]
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
141 else
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
142 lheader="((struct lrecord_header *) -1)"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
143 lrecord_type=-1
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
144 imp="0xdeadbeef"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
145 fi
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
146 ## printvar obj val type imp
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
147 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
148
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
149 function xint {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
150 decode_object "$*"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
151 print (long) ($val)
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
152 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
153
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
154 document xtype << 'end'
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
155 Usage: xtype lisp_object
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
156 Print the Lisp type of a lisp object.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
157 end
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
158
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
159 function xtype {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
160 decode_object "$*"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
161 if test $type = $Lisp_Type_Int; then echo "int"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
162 elif test $type = $Lisp_Type_Char; then echo "char"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
163 elif test $type = null_pointer; then echo "null_pointer"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
164 else
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
165 echo "record type with name: $[((struct lrecord_implementation *)$imp)->name]"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
166 fi
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
167 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
168
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
169 function lisp-shadows {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
170 run -batch -vanilla -f list-load-path-shadows
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
171 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
172
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
173 function environment-to-run-temacs {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
174 unset EMACSLOADPATH
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
175 export EMACSBOOTSTRAPLOADPATH=../lisp/:..
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
176 export EMACSBOOTSTRAPMODULEPATH=../modules/:..
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
177 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
178
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
179 document run-temacs << 'end'
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
180 Usage: run-temacs
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
181 Run temacs interactively, like xemacs.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
182 Use this with debugging tools (like purify) that cannot deal with dumping,
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
183 or when temacs builds successfully, but xemacs does not.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
184 end
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
185
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
186 function run-temacs {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
187 environment-to-run-temacs
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
188 run -nd -batch -l ../lisp/loadup.el run-temacs -q ${1+"$@"}
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
189 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
190
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
191 document check-xemacs << 'end'
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
192 Usage: check-xemacs
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
193 Run the test suite. Equivalent to 'make check'.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
194 end
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
195
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
196 function check-xemacs {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
197 run -batch -l ../tests/automated/test-harness.el -f batch-test-emacs ../tests/automated
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
198 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
199
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
200 document check-temacs << 'end'
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
201 Usage: check-temacs
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
202 Run the test suite on temacs. Equivalent to 'make check-temacs'.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
203 Use this with debugging tools (like purify) that cannot deal with dumping,
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
204 or when temacs builds successfully, but xemacs does not.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
205 end
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
206
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
207 function check-temacs {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
208 run-temacs -q -batch -l ../tests/automated/test-harness.el -f batch-test-emacs ../tests/automated
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
209 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
210
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
211 document update-elc << 'end'
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
212 Usage: update-elc
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
213 Run the core lisp byte compilation part of the build procedure.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
214 Use when debugging temacs, not xemacs!
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
215 Use this when temacs builds successfully, but xemacs does not.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
216 end
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
217
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
218 function update-elc {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
219 environment-to-run-temacs
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
220 run -nd -batch -l ../lisp/update-elc.el
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
221 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
222
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
223 document dmp << 'end'
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
224 Usage: dmp
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
225 Run the dumping part of the build procedure.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
226 Use when debugging temacs, not xemacs!
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
227 Use this when temacs builds successfully, but xemacs does not.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
228 end
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
229
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
230 function dmp {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
231 environment-to-run-temacs
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
232 run -nd -batch -l ../lisp/loadup.el dump
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
233 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
234
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
235 function pstruct { ## pstruct foo.c struct-name
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
236 module "$1" > /dev/null
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
237 type_ptr="((struct $2 *) $val)"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
238 print $type_ptr
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
239 print *$type_ptr
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
240 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
241
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
242 document pobj << 'end'
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
243 Usage: pobj lisp_object
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
244 Print the internal C representation of a Lisp Object.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
245 end
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
246
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
247 function pobj {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
248 decode_object $1
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
249 if test $type = $Lisp_Type_Int; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
250 print -f"Integer: %d" $val
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
251 elif test $type = $Lisp_Type_Char; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
252 if test $[$val > 32 && $val < 128] = 1; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
253 print -f"Char: %c" $val
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
254 else
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
255 print -f"Char: %d" $val
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
256 fi
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
257 elif test $lrecord_type = lrecord_type_string; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
258 pstruct alloc.c Lisp_String
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
259 elif test $lrecord_type = lrecord_type_cons; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
260 pstruct alloc.c Lisp_Cons
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
261 elif test $lrecord_type = lrecord_type_symbol; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
262 pstruct symbols.c Lisp_Symbol
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
263 echo "Symbol name: $[(char *)($type_ptr->name->data)]"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
264 elif test $lrecord_type = lrecord_type_vector; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
265 pstruct alloc.c Lisp_Vector
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
266 echo "Vector of length $[$type_ptr->size]"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
267 elif test $lrecord_type = lrecord_type_bit_vector; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
268 pstruct fns.c Lisp_Bit_Vector
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
269 elif test $lrecord_type = lrecord_type_buffer; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
270 pstruct buffer.c buffer
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
271 elif test $lrecord_type = lrecord_type_char_table; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
272 pstruct chartab.c Lisp_Char_Table
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
273 elif test $lrecord_type = lrecord_type_char_table_entry; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
274 pstruct chartab.c Lisp_Char_Table_Entry
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
275 elif test $lrecord_type = lrecord_type_charset; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
276 pstruct mule-charset.c Lisp_Charset
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
277 elif test $lrecord_type = lrecord_type_coding_system; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
278 pstruct file-coding.c Lisp_Coding_System
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
279 elif test $lrecord_type = lrecord_type_color_instance; then
5176
8b2f75cecb89 rename objects* (.c, .h and .el files) to fontcolor*
Ben Wing <ben@xemacs.org>
parents: 3418
diff changeset
280 pstruct fontcolor.c Lisp_Color_Instance
3418
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
281 elif test $lrecord_type = lrecord_type_command_builder; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
282 pstruct event-stream.c command_builder
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
283 elif test $lrecord_type = lrecord_type_compiled_function; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
284 pstruct bytecode.c Lisp_Compiled_Function
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
285 elif test $lrecord_type = lrecord_type_console; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
286 pstruct console.c console
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
287 elif test $lrecord_type = lrecord_type_database; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
288 pstruct database.c Lisp_Database
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
289 elif test $lrecord_type = lrecord_type_device; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
290 pstruct device.c device
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
291 elif test $lrecord_type = lrecord_type_event; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
292 pstruct events.c Lisp_Event
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
293 elif test $lrecord_type = lrecord_type_extent; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
294 pstruct extents.c extent
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
295 elif test $lrecord_type = lrecord_type_extent_auxiliary; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
296 pstruct extents.c extent_auxiliary
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
297 elif test $lrecord_type = lrecord_type_extent_info; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
298 pstruct extents.c extent_info
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
299 elif test $lrecord_type = lrecord_type_face; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
300 pstruct faces.c Lisp_Face
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
301 elif test $lrecord_type = lrecord_type_float; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
302 pstruct floatfns.c Lisp_Float
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
303 elif test $lrecord_type = lrecord_type_font_instance; then
5176
8b2f75cecb89 rename objects* (.c, .h and .el files) to fontcolor*
Ben Wing <ben@xemacs.org>
parents: 3418
diff changeset
304 pstruct fontcolor.c Lisp_Font_Instance
3418
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
305 elif test $lrecord_type = lrecord_type_frame; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
306 pstruct frame.c frame
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
307 elif test $lrecord_type = lrecord_type_glyph; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
308 pstruct glyph.c Lisp_Glyph
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
309 elif test $lrecord_type = lrecord_type_gui_item; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
310 pstruct gui.c Lisp_Gui_Item
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
311 elif test $lrecord_type = lrecord_type_hash_table; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
312 pstruct elhash.c Lisp_Hash_Table
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
313 elif test $lrecord_type = lrecord_type_image_instance; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
314 pstruct glyphs.c Lisp_Image_Instance
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
315 elif test $lrecord_type = lrecord_type_keymap; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
316 pstruct keymap.c Lisp_Keymap
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
317 elif test $lrecord_type = lrecord_type_lcrecord_list; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
318 pstruct alloc.c lcrecord_list
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
319 elif test $lrecord_type = lrecord_type_ldap; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
320 pstruct ldap.c Lisp_LDAP
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
321 elif test $lrecord_type = lrecord_type_lstream; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
322 pstruct lstream.c lstream
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
323 elif test $lrecord_type = lrecord_type_marker; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
324 pstruct marker.c Lisp_Marker
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
325 elif test $lrecord_type = lrecord_type_opaque; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
326 pstruct opaque.c Lisp_Opaque
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
327 elif test $lrecord_type = lrecord_type_opaque_ptr; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
328 pstruct opaque.c Lisp_Opaque_Ptr
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
329 elif test $lrecord_type = lrecord_type_popup_data; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
330 pstruct gui-x.c popup_data
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
331 elif test $lrecord_type = lrecord_type_process; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
332 pstruct process.c Lisp_Process
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
333 elif test $lrecord_type = lrecord_type_range_table; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
334 pstruct rangetab.c Lisp_Range_Table
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
335 elif test $lrecord_type = lrecord_type_specifier; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
336 pstruct specifier.c Lisp_Specifier
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
337 elif test $lrecord_type = lrecord_type_subr; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
338 pstruct eval.c Lisp_Subr
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
339 elif test $lrecord_type = lrecord_type_symbol_value_buffer_local; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
340 pstruct symbols.c symbol_value_buffer_local
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
341 elif test $lrecord_type = lrecord_type_symbol_value_forward; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
342 pstruct symbols.c symbol_value_forward
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
343 elif test $lrecord_type = lrecord_type_symbol_value_lisp_magic; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
344 pstruct symbols.c symbol_value_lisp_magic
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
345 elif test $lrecord_type = lrecord_type_symbol_value_varalias; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
346 pstruct symbols.c symbol_value_varalias
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
347 elif test $lrecord_type = lrecord_type_timeout; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
348 pstruct event-stream.c Lisp_Timeout
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
349 elif test $lrecord_type = lrecord_type_toolbar_button; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
350 pstruct toolbar.c toolbar_button
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
351 elif test $lrecord_type = lrecord_type_tooltalk_message; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
352 pstruct tooltalk.c Lisp_Tooltalk_Message
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
353 elif test $lrecord_type = lrecord_type_tooltalk_pattern; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
354 pstruct tooltalk.c Lisp_Tooltalk_Pattern
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
355 elif test $lrecord_type = lrecord_type_weak_list; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
356 pstruct data.c weak_list
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
357 elif test $lrecord_type = lrecord_type_window; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
358 pstruct window.c window
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
359 elif test $lrecord_type = lrecord_type_window_configuration; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
360 pstruct window.c window_config
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
361 elif test "$type" = "null_pointer"; then
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
362 echo "Lisp Object is a null pointer!!"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
363 else
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
364 echo "Unknown Lisp Object type"
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
365 print $1
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
366 fi
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
367 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
368
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
369 dbxenv suppress_startup_message 4.0
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
370 ## dbxenv mt_watchpoints on
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
371
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
372 function dp_core {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
373 print ((struct x_frame *)(((struct frame*)(Fselected_frame(Qnil)&0x00FFFFFF))->frame_data))->widget->core
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
374 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
375
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
376 ## Barf!
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
377 function print_shell {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
378 print *(`frame-x.c`TopLevelShellRec*) (((struct `frame-x.c`x_frame*) (((struct `frame-x.c`frame*) (Fselected_frame(Qnil)&0x00FFFFFF))->frame_data))->widget)
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
379 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
380
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
381 ## -------------------------------------------------------------
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
382 ## functions to test the debugging support itself.
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
383 ## If you change this file, make sure the following still work...
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
384 ## -------------------------------------------------------------
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
385 function test_xtype {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
386 function doit { echo -n "$1: "; xtype "$1"; }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
387 test_various_objects
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
388 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
389
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
390 function test_pobj {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
391 function doit { echo '==============================='; echo -n "$1: "; pobj "$1"; }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
392 test_various_objects
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
393 }
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
394
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
395 function test_various_objects {
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
396 doit Vemacs_major_version
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
397 doit Vhelp_char
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
398 doit Qnil
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
399 doit Qunbound
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
400 doit Vobarray
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
401 doit Vall_weak_lists
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
402 doit Vxemacs_codename
a1e20876b806 [xemacs-hg @ 2006-05-23 13:18:50 by stephent]
stephent
parents:
diff changeset
403 }