comparison src/.gdbinit @ 90737:95d0cdf160ea

Merge from emacs--devo--0 Patches applied: * emacs--devo--0 (patch 586-614) - Update from CVS - Update from erc--emacs--22 - Merge from gnus--rel--5.10 - Merge from erc--main--0 - Make byte compiler correctly write circular constants * gnus--rel--5.10 (patch 186-196) - Update from CVS - Merge from emacs--devo--0 Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-162
author Miles Bader <miles@gnu.org>
date Fri, 26 Jan 2007 06:16:11 +0000
parents bc10a33dd40b b8533eb9045d
children dd7c098af727
comparison
equal deleted inserted replaced
90736:ef1369583937 90737:95d0cdf160ea
1 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2001, 1 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2001,
2 # 2004, 2005, 2006 Free Software Foundation, Inc. 2 # 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
3 # 3 #
4 # This file is part of GNU Emacs. 4 # This file is part of GNU Emacs.
5 # 5 #
6 # GNU Emacs is free software; you can redistribute it and/or modify 6 # GNU Emacs is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by 7 # it under the terms of the GNU General Public License as published by
156 printf "[%d]", $t->gpt_byte 156 printf "[%d]", $t->gpt_byte
157 end 157 end
158 printf " SZ=%d\n", $t->gap_size 158 printf " SZ=%d\n", $t->gap_size
159 end 159 end
160 document ppt 160 document ppt
161 Print point, beg, end, narrow, and gap for current buffer. 161 Print current buffer's point and boundaries.
162 Prints values of point, beg, end, narrow, and gap for current buffer.
162 end 163 end
163 164
164 # Print out iterator given as first arg 165 # Print out iterator given as first arg
165 define pitx 166 define pitx
166 set $it = $arg0 167 set $it = $arg0
310 define pcursorx 311 define pcursorx
311 set $cp = $arg0 312 set $cp = $arg0
312 printf "y=%d x=%d vpos=%d hpos=%d", $cp->y, $cp->x, $cp->vpos, $cp->hpos 313 printf "y=%d x=%d vpos=%d hpos=%d", $cp->y, $cp->x, $cp->vpos, $cp->hpos
313 end 314 end
314 document pcursorx 315 document pcursorx
315 Pretty print a window cursor 316 Pretty print a window cursor.
316 end 317 end
317 318
318 define pcursor 319 define pcursor
319 printf "output: " 320 printf "output: "
320 pcursorx output_cursor 321 pcursorx output_cursor
321 printf "\n" 322 printf "\n"
322 end 323 end
323 document pcursor 324 document pcursor
324 Pretty print the output_cursor 325 Pretty print the output_cursor.
325 end 326 end
326 327
327 define pwinx 328 define pwinx
328 set $w = $arg0 329 set $w = $arg0
329 xgetint $w->sequence_number 330 xgetint $w->sequence_number
379 end 380 end
380 printf "\n" 381 printf "\n"
381 end 382 end
382 document pwinx 383 document pwinx
383 Pretty print a window structure. 384 Pretty print a window structure.
384 Takes one argument, a pointer to a window structure 385 Takes one argument, a pointer to a window structure.
385 end 386 end
386 387
387 define pwin 388 define pwin
388 pwinx w 389 pwinx w
389 end 390 end
445 end 446 end
446 printf "\n" 447 printf "\n"
447 end 448 end
448 document pgx 449 document pgx
449 Pretty print a glyph structure. 450 Pretty print a glyph structure.
450 Takes one argument, a pointer to a glyph structure 451 Takes one argument, a pointer to a glyph structure.
451 end 452 end
452 453
453 define pg 454 define pg
454 set $pgidx = 0 455 set $pgidx = 0
455 pgx glyph 456 pgx glyph
530 set $size = ((struct Lisp_Vector *) $ptr)->size 531 set $size = ((struct Lisp_Vector *) $ptr)->size
531 output ($size & PVEC_FLAG) ? (enum pvec_type) ($size & PVEC_TYPE_MASK) : $size & ~gdb_array_mark_flag 532 output ($size & PVEC_FLAG) ? (enum pvec_type) ($size & PVEC_TYPE_MASK) : $size & ~gdb_array_mark_flag
532 echo \n 533 echo \n
533 end 534 end
534 document xvectype 535 document xvectype
535 Print the size or vector subtype of $, assuming it is a vector or pseudovector. 536 Print the size or vector subtype of $.
537 This command assumes that $ is a vector or pseudovector.
536 end 538 end
537 539
538 define xmisctype 540 define xmisctype
539 xgetptr $ 541 xgetptr $
540 output (enum Lisp_Misc_Type) (((struct Lisp_Free *) $ptr)->type) 542 output (enum Lisp_Misc_Type) (((struct Lisp_Free *) $ptr)->type)
541 echo \n 543 echo \n
542 end 544 end
543 document xmisctype 545 document xmisctype
544 Print the specific type of $, assuming it is some misc type. 546 Assume that $ is some misc type and print its specific type.
545 end 547 end
546 548
547 define xint 549 define xint
548 xgetint $ 550 xgetint $
549 print $int 551 print $int
550 end 552 end
551 document xint 553 document xint
552 Print $, assuming it is an Emacs Lisp integer. This gets the sign right. 554 Print $ as an Emacs Lisp integer. This gets the sign right.
553 end 555 end
554 556
555 define xptr 557 define xptr
556 xgetptr $ 558 xgetptr $
557 print (void *) $ptr 559 print (void *) $ptr
558 end 560 end
559 document xptr 561 document xptr
560 Print the pointer portion of $, assuming it is an Emacs Lisp value. 562 Print the pointer portion of an Emacs Lisp value in $.
561 end 563 end
562 564
563 define xmarker 565 define xmarker
564 xgetptr $ 566 xgetptr $
565 print (struct Lisp_Marker *) $ptr 567 print (struct Lisp_Marker *) $ptr
566 end 568 end
567 document xmarker 569 document xmarker
568 Print $ as a marker pointer, assuming it is an Emacs Lisp marker value. 570 Print $ as a marker pointer.
571 This command assumes that $ is an Emacs Lisp marker value.
569 end 572 end
570 573
571 define xoverlay 574 define xoverlay
572 xgetptr $ 575 xgetptr $
573 print (struct Lisp_Overlay *) $ptr 576 print (struct Lisp_Overlay *) $ptr
574 end 577 end
575 document xoverlay 578 document xoverlay
576 Print $ as a overlay pointer, assuming it is an Emacs Lisp overlay value. 579 Print $ as a overlay pointer.
580 This command assumes that $ is an Emacs Lisp overlay value.
577 end 581 end
578 582
579 define xmiscfree 583 define xmiscfree
580 xgetptr $ 584 xgetptr $
581 print (struct Lisp_Free *) $ptr 585 print (struct Lisp_Free *) $ptr
582 end 586 end
583 document xmiscfree 587 document xmiscfree
584 Print $ as a misc free-cell pointer, assuming it is an Emacs Lisp Misc value. 588 Print $ as a misc free-cell pointer.
589 This command assumes that $ is an Emacs Lisp Misc value.
585 end 590 end
586 591
587 define xintfwd 592 define xintfwd
588 xgetptr $ 593 xgetptr $
589 print (struct Lisp_Intfwd *) $ptr 594 print (struct Lisp_Intfwd *) $ptr
590 end 595 end
591 document xintfwd 596 document xintfwd
592 Print $ as an integer forwarding pointer, assuming it is an Emacs Lisp Misc value. 597 Print $ as an integer forwarding pointer.
598 This command assumes that $ is an Emacs Lisp Misc value.
593 end 599 end
594 600
595 define xboolfwd 601 define xboolfwd
596 xgetptr $ 602 xgetptr $
597 print (struct Lisp_Boolfwd *) $ptr 603 print (struct Lisp_Boolfwd *) $ptr
598 end 604 end
599 document xboolfwd 605 document xboolfwd
600 Print $ as a boolean forwarding pointer, assuming it is an Emacs Lisp Misc value. 606 Print $ as a boolean forwarding pointer.
607 This command assumes that $ is an Emacs Lisp Misc value.
601 end 608 end
602 609
603 define xobjfwd 610 define xobjfwd
604 xgetptr $ 611 xgetptr $
605 print (struct Lisp_Objfwd *) $ptr 612 print (struct Lisp_Objfwd *) $ptr
606 end 613 end
607 document xobjfwd 614 document xobjfwd
608 Print $ as an object forwarding pointer, assuming it is an Emacs Lisp Misc value. 615 Print $ as an object forwarding pointer.
616 This command assumes that $ is an Emacs Lisp Misc value.
609 end 617 end
610 618
611 define xbufobjfwd 619 define xbufobjfwd
612 xgetptr $ 620 xgetptr $
613 print (struct Lisp_Buffer_Objfwd *) $ptr 621 print (struct Lisp_Buffer_Objfwd *) $ptr
614 end 622 end
615 document xbufobjfwd 623 document xbufobjfwd
616 Print $ as a buffer-local object forwarding pointer, assuming it is an Emacs Lisp Misc value. 624 Print $ as a buffer-local object forwarding pointer.
625 This command assumes that $ is an Emacs Lisp Misc value.
617 end 626 end
618 627
619 define xkbobjfwd 628 define xkbobjfwd
620 xgetptr $ 629 xgetptr $
621 print (struct Lisp_Kboard_Objfwd *) $ptr 630 print (struct Lisp_Kboard_Objfwd *) $ptr
622 end 631 end
623 document xkbobjfwd 632 document xkbobjfwd
624 Print $ as a kboard-local object forwarding pointer, assuming it is an Emacs Lisp Misc value. 633 Print $ as a kboard-local object forwarding pointer.
634 This command assumes that $ is an Emacs Lisp Misc value.
625 end 635 end
626 636
627 define xbuflocal 637 define xbuflocal
628 xgetptr $ 638 xgetptr $
629 print (struct Lisp_Buffer_Local_Value *) $ptr 639 print (struct Lisp_Buffer_Local_Value *) $ptr
630 end 640 end
631 document xbuflocal 641 document xbuflocal
632 Print $ as a buffer-local-value pointer, assuming it is an Emacs Lisp Misc value. 642 Print $ as a buffer-local-value pointer.
643 This command assumes that $ is an Emacs Lisp Misc value.
633 end 644 end
634 645
635 define xsymbol 646 define xsymbol
636 set $sym = $ 647 set $sym = $
637 xgetptr $sym 648 xgetptr $sym
671 print (struct Lisp_Process *) $ptr 682 print (struct Lisp_Process *) $ptr
672 output *$ 683 output *$
673 echo \n 684 echo \n
674 end 685 end
675 document xprocess 686 document xprocess
676 Print the address of the struct Lisp_process which the Lisp_Object $ points to. 687 Print the address of the struct Lisp_process to which $ points.
688 This command assumes that $ is a Lisp_Object.
677 end 689 end
678 690
679 define xframe 691 define xframe
680 xgetptr $ 692 xgetptr $
681 print (struct frame *) $ptr 693 print (struct frame *) $ptr
683 set $ptr = (struct Lisp_String *) $ptr 695 set $ptr = (struct Lisp_String *) $ptr
684 xprintstr $ptr 696 xprintstr $ptr
685 echo \n 697 echo \n
686 end 698 end
687 document xframe 699 document xframe
688 Print $ as a frame pointer, assuming it is an Emacs Lisp frame value. 700 Print $ as a frame pointer.
701 This command assumes $ is an Emacs Lisp frame value.
689 end 702 end
690 703
691 define xcompiled 704 define xcompiled
692 xgetptr $ 705 xgetptr $
693 print (struct Lisp_Vector *) $ptr 706 print (struct Lisp_Vector *) $ptr
694 output ($->contents[0])@($->size & 0xff) 707 output ($->contents[0])@($->size & 0xff)
695 end 708 end
696 document xcompiled 709 document xcompiled
697 Print $ as a compiled function pointer, assuming it is an Emacs Lisp compiled value. 710 Print $ as a compiled function pointer.
711 This command assumes that $ is an Emacs Lisp compiled value.
698 end 712 end
699 713
700 define xwindow 714 define xwindow
701 xgetptr $ 715 xgetptr $
702 print (struct window *) $ptr 716 print (struct window *) $ptr
719 define xwinconfig 733 define xwinconfig
720 xgetptr $ 734 xgetptr $
721 print (struct save_window_data *) $ptr 735 print (struct save_window_data *) $ptr
722 end 736 end
723 document xwinconfig 737 document xwinconfig
724 Print $ as a window configuration pointer, assuming it is an Emacs Lisp window configuration value. 738 Print $ as a window configuration pointer.
739 This command assumes that $ is an Emacs Lisp window configuration value.
725 end 740 end
726 741
727 define xsubr 742 define xsubr
728 xgetptr $ 743 xgetptr $
729 print (struct Lisp_Subr *) $ptr 744 print (struct Lisp_Subr *) $ptr
764 xgetptr $->name 779 xgetptr $->name
765 output ((struct Lisp_String *) $ptr)->data 780 output ((struct Lisp_String *) $ptr)->data
766 echo \n 781 echo \n
767 end 782 end
768 document xbuffer 783 document xbuffer
769 Set $ as a buffer pointer, assuming it is an Emacs Lisp buffer value. 784 Set $ as a buffer pointer and the name of the buffer.
770 Print the name of the buffer. 785 This command assumes $ is an Emacs Lisp buffer value.
771 end 786 end
772 787
773 define xhashtable 788 define xhashtable
774 xgetptr $ 789 xgetptr $
775 print (struct Lisp_Hash_Table *) $ptr 790 print (struct Lisp_Hash_Table *) $ptr
776 end 791 end
777 document xhashtable 792 document xhashtable
778 Set $ as a hash table pointer, assuming it is an Emacs Lisp hash table value. 793 Set $ as a hash table pointer.
794 This command assumes that $ is an Emacs Lisp hash table value.
779 end 795 end
780 796
781 define xcons 797 define xcons
782 xgetptr $ 798 xgetptr $
783 print (struct Lisp_Cons *) $ptr 799 print (struct Lisp_Cons *) $ptr
784 output/x *$ 800 output/x *$
785 echo \n 801 echo \n
786 end 802 end
787 document xcons 803 document xcons
788 Print the contents of $, assuming it is an Emacs Lisp cons. 804 Print the contents of $ as an Emacs Lisp cons.
789 end 805 end
790 806
791 define nextcons 807 define nextcons
792 p $.u.cdr 808 p $.u.cdr
793 xcons 809 xcons
794 end 810 end
795 document nextcons 811 document nextcons
796 Print the contents of the next cell in a list. 812 Print the contents of the next cell in a list.
797 This assumes that the last thing you printed was a cons cell contents 813 This command assumes that the last thing you printed was a cons cell contents
798 (type struct Lisp_Cons) or a pointer to one. 814 (type struct Lisp_Cons) or a pointer to one.
799 end 815 end
800 define xcar 816 define xcar
801 xgetptr $ 817 xgetptr $
802 xgettype $ 818 xgettype $
803 print/x ($type == Lisp_Cons ? ((struct Lisp_Cons *) $ptr)->car : 0) 819 print/x ($type == Lisp_Cons ? ((struct Lisp_Cons *) $ptr)->car : 0)
804 end 820 end
805 document xcar 821 document xcar
806 Print the car of $, assuming it is an Emacs Lisp pair. 822 Assume that $ is an Emacs Lisp pair and print its car.
807 end 823 end
808 824
809 define xcdr 825 define xcdr
810 xgetptr $ 826 xgetptr $
811 xgettype $ 827 xgettype $
812 print/x ($type == Lisp_Cons ? ((struct Lisp_Cons *) $ptr)->u.cdr : 0) 828 print/x ($type == Lisp_Cons ? ((struct Lisp_Cons *) $ptr)->u.cdr : 0)
813 end 829 end
814 document xcdr 830 document xcdr
815 Print the cdr of $, assuming it is an Emacs Lisp pair. 831 Assume that $ is an Emacs Lisp pair and print its cdr.
816 end 832 end
817 833
818 define xlist 834 define xlist
819 xgetptr $ 835 xgetptr $
820 set $cons = (struct Lisp_Cons *) $ptr 836 set $cons = (struct Lisp_Cons *) $ptr
1028 1044
1029 define which 1045 define which
1030 set debug_print (which_symbols ($arg0)) 1046 set debug_print (which_symbols ($arg0))
1031 end 1047 end
1032 document which 1048 document which
1033 Print symbols which references a given lisp object, 1049 Print symbols which references a given lisp object
1034 either as its symbol value or symbol function. 1050 either as its symbol value or symbol function.
1035 end 1051 end
1036 1052
1037 define xbytecode 1053 define xbytecode
1038 set $bt = byte_stack_list 1054 set $bt = byte_stack_list