diff options
Diffstat (limited to 'src/lisp.h')
| -rw-r--r-- | src/lisp.h | 402 |
1 files changed, 168 insertions, 234 deletions
diff --git a/src/lisp.h b/src/lisp.h index 3a6d247f6d5..1f18b5e0775 100644 --- a/src/lisp.h +++ b/src/lisp.h | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | /* Fundamental definitions for GNU Emacs Lisp interpreter. | 1 | /* Fundamental definitions for GNU Emacs Lisp interpreter. |
| 2 | 2 | ||
| 3 | Copyright (C) 1985-1987, 1993-1995, 1997-2014 Free Software Foundation, | 3 | Copyright (C) 1985-1987, 1993-1995, 1997-2015 Free Software Foundation, |
| 4 | Inc. | 4 | Inc. |
| 5 | 5 | ||
| 6 | This file is part of GNU Emacs. | 6 | This file is part of GNU Emacs. |
| @@ -354,9 +354,11 @@ error !; | |||
| 354 | #define lisp_h_XCONS(a) \ | 354 | #define lisp_h_XCONS(a) \ |
| 355 | (eassert (CONSP (a)), (struct Lisp_Cons *) XUNTAG (a, Lisp_Cons)) | 355 | (eassert (CONSP (a)), (struct Lisp_Cons *) XUNTAG (a, Lisp_Cons)) |
| 356 | #define lisp_h_XHASH(a) XUINT (a) | 356 | #define lisp_h_XHASH(a) XUINT (a) |
| 357 | #define lisp_h_XPNTR(a) ((void *) (intptr_t) (XLI (a) & VALMASK)) | 357 | #define lisp_h_XPNTR(a) \ |
| 358 | (SYMBOLP (a) ? XSYMBOL (a) : (void *) ((intptr_t) (XLI (a) & VALMASK))) | ||
| 358 | #define lisp_h_XSYMBOL(a) \ | 359 | #define lisp_h_XSYMBOL(a) \ |
| 359 | (eassert (SYMBOLP (a)), (struct Lisp_Symbol *) XUNTAG (a, Lisp_Symbol)) | 360 | (eassert (SYMBOLP (a)), \ |
| 361 | (struct Lisp_Symbol *) XUNTAGBASE (a, Lisp_Symbol, lispsym)) | ||
| 360 | #ifndef GC_CHECK_CONS_LIST | 362 | #ifndef GC_CHECK_CONS_LIST |
| 361 | # define lisp_h_check_cons_list() ((void) 0) | 363 | # define lisp_h_check_cons_list() ((void) 0) |
| 362 | #endif | 364 | #endif |
| @@ -366,7 +368,9 @@ error !; | |||
| 366 | # define lisp_h_XFASTINT(a) XINT (a) | 368 | # define lisp_h_XFASTINT(a) XINT (a) |
| 367 | # define lisp_h_XINT(a) (XLI (a) >> INTTYPEBITS) | 369 | # define lisp_h_XINT(a) (XLI (a) >> INTTYPEBITS) |
| 368 | # define lisp_h_XTYPE(a) ((enum Lisp_Type) (XLI (a) & ~VALMASK)) | 370 | # define lisp_h_XTYPE(a) ((enum Lisp_Type) (XLI (a) & ~VALMASK)) |
| 369 | # define lisp_h_XUNTAG(a, type) ((void *) (XLI (a) - (type))) | 371 | # define lisp_h_XUNTAG(a, type) XUNTAGBASE (a, type, 0) |
| 372 | # define lisp_h_XUNTAGBASE(a, type, base) \ | ||
| 373 | ((void *) ((char *) (base) - (type) + (intptr_t) XLI (a))) | ||
| 370 | #endif | 374 | #endif |
| 371 | 375 | ||
| 372 | /* When compiling via gcc -O0, define the key operations as macros, as | 376 | /* When compiling via gcc -O0, define the key operations as macros, as |
| @@ -408,6 +412,7 @@ error !; | |||
| 408 | # define XINT(a) lisp_h_XINT (a) | 412 | # define XINT(a) lisp_h_XINT (a) |
| 409 | # define XTYPE(a) lisp_h_XTYPE (a) | 413 | # define XTYPE(a) lisp_h_XTYPE (a) |
| 410 | # define XUNTAG(a, type) lisp_h_XUNTAG (a, type) | 414 | # define XUNTAG(a, type) lisp_h_XUNTAG (a, type) |
| 415 | # define XUNTAGBASE(a, type, base) lisp_h_XUNTAGBASE (a, type, base) | ||
| 411 | # endif | 416 | # endif |
| 412 | #endif | 417 | #endif |
| 413 | 418 | ||
| @@ -447,20 +452,20 @@ error !; | |||
| 447 | 452 | ||
| 448 | enum Lisp_Type | 453 | enum Lisp_Type |
| 449 | { | 454 | { |
| 450 | /* Integer. XINT (obj) is the integer value. */ | ||
| 451 | Lisp_Int0 = 0, | ||
| 452 | Lisp_Int1 = USE_LSB_TAG ? 1 << INTTYPEBITS : 1, | ||
| 453 | |||
| 454 | /* Symbol. XSYMBOL (object) points to a struct Lisp_Symbol. */ | 455 | /* Symbol. XSYMBOL (object) points to a struct Lisp_Symbol. */ |
| 455 | Lisp_Symbol = 2, | 456 | Lisp_Symbol = 0, |
| 456 | 457 | ||
| 457 | /* Miscellaneous. XMISC (object) points to a union Lisp_Misc, | 458 | /* Miscellaneous. XMISC (object) points to a union Lisp_Misc, |
| 458 | whose first member indicates the subtype. */ | 459 | whose first member indicates the subtype. */ |
| 459 | Lisp_Misc = 3, | 460 | Lisp_Misc = 1, |
| 461 | |||
| 462 | /* Integer. XINT (obj) is the integer value. */ | ||
| 463 | Lisp_Int0 = 2, | ||
| 464 | Lisp_Int1 = USE_LSB_TAG ? 6 : 3, | ||
| 460 | 465 | ||
| 461 | /* String. XSTRING (object) points to a struct Lisp_String. | 466 | /* String. XSTRING (object) points to a struct Lisp_String. |
| 462 | The length of the string, and its contents, are stored therein. */ | 467 | The length of the string, and its contents, are stored therein. */ |
| 463 | Lisp_String = USE_LSB_TAG ? 1 : 1 << INTTYPEBITS, | 468 | Lisp_String = 4, |
| 464 | 469 | ||
| 465 | /* Vector of Lisp objects, or something resembling it. | 470 | /* Vector of Lisp objects, or something resembling it. |
| 466 | XVECTOR (object) points to a struct Lisp_Vector, which contains | 471 | XVECTOR (object) points to a struct Lisp_Vector, which contains |
| @@ -469,7 +474,7 @@ enum Lisp_Type | |||
| 469 | Lisp_Vectorlike = 5, | 474 | Lisp_Vectorlike = 5, |
| 470 | 475 | ||
| 471 | /* Cons. XCONS (object) points to a struct Lisp_Cons. */ | 476 | /* Cons. XCONS (object) points to a struct Lisp_Cons. */ |
| 472 | Lisp_Cons = 6, | 477 | Lisp_Cons = USE_LSB_TAG ? 3 : 6, |
| 473 | 478 | ||
| 474 | Lisp_Float = 7 | 479 | Lisp_Float = 7 |
| 475 | }; | 480 | }; |
| @@ -562,7 +567,7 @@ enum Lisp_Fwd_Type | |||
| 562 | 567 | ||
| 563 | typedef struct { EMACS_INT i; } Lisp_Object; | 568 | typedef struct { EMACS_INT i; } Lisp_Object; |
| 564 | 569 | ||
| 565 | #define LISP_INITIALLY_ZERO {0} | 570 | #define LISP_INITIALLY(i) {i} |
| 566 | 571 | ||
| 567 | #undef CHECK_LISP_OBJECT_TYPE | 572 | #undef CHECK_LISP_OBJECT_TYPE |
| 568 | enum CHECK_LISP_OBJECT_TYPE { CHECK_LISP_OBJECT_TYPE = true }; | 573 | enum CHECK_LISP_OBJECT_TYPE { CHECK_LISP_OBJECT_TYPE = true }; |
| @@ -571,9 +576,11 @@ enum CHECK_LISP_OBJECT_TYPE { CHECK_LISP_OBJECT_TYPE = true }; | |||
| 571 | /* If a struct type is not wanted, define Lisp_Object as just a number. */ | 576 | /* If a struct type is not wanted, define Lisp_Object as just a number. */ |
| 572 | 577 | ||
| 573 | typedef EMACS_INT Lisp_Object; | 578 | typedef EMACS_INT Lisp_Object; |
| 574 | #define LISP_INITIALLY_ZERO 0 | 579 | #define LISP_INITIALLY(i) (i) |
| 575 | enum CHECK_LISP_OBJECT_TYPE { CHECK_LISP_OBJECT_TYPE = false }; | 580 | enum CHECK_LISP_OBJECT_TYPE { CHECK_LISP_OBJECT_TYPE = false }; |
| 576 | #endif /* CHECK_LISP_OBJECT_TYPE */ | 581 | #endif /* CHECK_LISP_OBJECT_TYPE */ |
| 582 | |||
| 583 | #define LISP_INITIALLY_ZERO LISP_INITIALLY (0) | ||
| 577 | 584 | ||
| 578 | /* Forward declarations. */ | 585 | /* Forward declarations. */ |
| 579 | 586 | ||
| @@ -604,18 +611,14 @@ INLINE bool (SYMBOLP) (Lisp_Object); | |||
| 604 | INLINE bool (VECTORLIKEP) (Lisp_Object); | 611 | INLINE bool (VECTORLIKEP) (Lisp_Object); |
| 605 | INLINE bool WINDOWP (Lisp_Object); | 612 | INLINE bool WINDOWP (Lisp_Object); |
| 606 | INLINE struct Lisp_Save_Value *XSAVE_VALUE (Lisp_Object); | 613 | INLINE struct Lisp_Save_Value *XSAVE_VALUE (Lisp_Object); |
| 614 | INLINE struct Lisp_Symbol *(XSYMBOL) (Lisp_Object); | ||
| 615 | INLINE void *(XUNTAGBASE) (Lisp_Object, int, void *); | ||
| 607 | 616 | ||
| 608 | /* Defined in chartab.c. */ | 617 | /* Defined in chartab.c. */ |
| 609 | extern Lisp_Object char_table_ref (Lisp_Object, int); | 618 | extern Lisp_Object char_table_ref (Lisp_Object, int); |
| 610 | extern void char_table_set (Lisp_Object, int, Lisp_Object); | 619 | extern void char_table_set (Lisp_Object, int, Lisp_Object); |
| 611 | 620 | ||
| 612 | /* Defined in data.c. */ | 621 | /* Defined in data.c. */ |
| 613 | extern Lisp_Object Qarrayp, Qbufferp, Qbuffer_or_string_p, Qchar_table_p; | ||
| 614 | extern Lisp_Object Qconsp, Qfloatp, Qintegerp, Qlambda, Qlistp, Qmarkerp, Qnil; | ||
| 615 | extern Lisp_Object Qnumberp, Qstringp, Qsymbolp, Qt, Qvectorp; | ||
| 616 | extern Lisp_Object Qbool_vector_p; | ||
| 617 | extern Lisp_Object Qvector_or_char_table_p, Qwholenump; | ||
| 618 | extern Lisp_Object Qwindow; | ||
| 619 | extern _Noreturn Lisp_Object wrong_type_argument (Lisp_Object, Lisp_Object); | 622 | extern _Noreturn Lisp_Object wrong_type_argument (Lisp_Object, Lisp_Object); |
| 620 | extern _Noreturn void wrong_choice (Lisp_Object, Lisp_Object); | 623 | extern _Noreturn void wrong_choice (Lisp_Object, Lisp_Object); |
| 621 | 624 | ||
| @@ -625,22 +628,120 @@ extern bool might_dump; | |||
| 625 | Used during startup to detect startup of dumped Emacs. */ | 628 | Used during startup to detect startup of dumped Emacs. */ |
| 626 | extern bool initialized; | 629 | extern bool initialized; |
| 627 | 630 | ||
| 628 | /* Defined in eval.c. */ | ||
| 629 | extern Lisp_Object Qautoload; | ||
| 630 | |||
| 631 | /* Defined in floatfns.c. */ | 631 | /* Defined in floatfns.c. */ |
| 632 | extern double extract_float (Lisp_Object); | 632 | extern double extract_float (Lisp_Object); |
| 633 | 633 | ||
| 634 | /* Defined in process.c. */ | 634 | |
| 635 | extern Lisp_Object Qprocessp; | 635 | /* Interned state of a symbol. */ |
| 636 | |||
| 637 | enum symbol_interned | ||
| 638 | { | ||
| 639 | SYMBOL_UNINTERNED = 0, | ||
| 640 | SYMBOL_INTERNED = 1, | ||
| 641 | SYMBOL_INTERNED_IN_INITIAL_OBARRAY = 2 | ||
| 642 | }; | ||
| 636 | 643 | ||
| 637 | /* Defined in window.c. */ | 644 | enum symbol_redirect |
| 638 | extern Lisp_Object Qwindowp; | 645 | { |
| 646 | SYMBOL_PLAINVAL = 4, | ||
| 647 | SYMBOL_VARALIAS = 1, | ||
| 648 | SYMBOL_LOCALIZED = 2, | ||
| 649 | SYMBOL_FORWARDED = 3 | ||
| 650 | }; | ||
| 651 | |||
| 652 | struct Lisp_Symbol | ||
| 653 | { | ||
| 654 | bool_bf gcmarkbit : 1; | ||
| 655 | |||
| 656 | /* Indicates where the value can be found: | ||
| 657 | 0 : it's a plain var, the value is in the `value' field. | ||
| 658 | 1 : it's a varalias, the value is really in the `alias' symbol. | ||
| 659 | 2 : it's a localized var, the value is in the `blv' object. | ||
| 660 | 3 : it's a forwarding variable, the value is in `forward'. */ | ||
| 661 | ENUM_BF (symbol_redirect) redirect : 3; | ||
| 662 | |||
| 663 | /* Non-zero means symbol is constant, i.e. changing its value | ||
| 664 | should signal an error. If the value is 3, then the var | ||
| 665 | can be changed, but only by `defconst'. */ | ||
| 666 | unsigned constant : 2; | ||
| 667 | |||
| 668 | /* Interned state of the symbol. This is an enumerator from | ||
| 669 | enum symbol_interned. */ | ||
| 670 | unsigned interned : 2; | ||
| 671 | |||
| 672 | /* True means that this variable has been explicitly declared | ||
| 673 | special (with `defvar' etc), and shouldn't be lexically bound. */ | ||
| 674 | bool_bf declared_special : 1; | ||
| 675 | |||
| 676 | /* True if pointed to from purespace and hence can't be GC'd. */ | ||
| 677 | bool_bf pinned : 1; | ||
| 678 | |||
| 679 | /* The symbol's name, as a Lisp string. */ | ||
| 680 | Lisp_Object name; | ||
| 681 | |||
| 682 | /* Value of the symbol or Qunbound if unbound. Which alternative of the | ||
| 683 | union is used depends on the `redirect' field above. */ | ||
| 684 | union { | ||
| 685 | Lisp_Object value; | ||
| 686 | struct Lisp_Symbol *alias; | ||
| 687 | struct Lisp_Buffer_Local_Value *blv; | ||
| 688 | union Lisp_Fwd *fwd; | ||
| 689 | } val; | ||
| 690 | |||
| 691 | /* Function value of the symbol or Qnil if not fboundp. */ | ||
| 692 | Lisp_Object function; | ||
| 693 | |||
| 694 | /* The symbol's property list. */ | ||
| 695 | Lisp_Object plist; | ||
| 696 | |||
| 697 | /* Next symbol in obarray bucket, if the symbol is interned. */ | ||
| 698 | struct Lisp_Symbol *next; | ||
| 699 | }; | ||
| 700 | |||
| 701 | /* Declare a Lisp-callable function. The MAXARGS parameter has the same | ||
| 702 | meaning as in the DEFUN macro, and is used to construct a prototype. */ | ||
| 703 | /* We can use the same trick as in the DEFUN macro to generate the | ||
| 704 | appropriate prototype. */ | ||
| 705 | #define EXFUN(fnname, maxargs) \ | ||
| 706 | extern Lisp_Object fnname DEFUN_ARGS_ ## maxargs | ||
| 707 | |||
| 708 | /* Note that the weird token-substitution semantics of ANSI C makes | ||
| 709 | this work for MANY and UNEVALLED. */ | ||
| 710 | #define DEFUN_ARGS_MANY (ptrdiff_t, Lisp_Object *) | ||
| 711 | #define DEFUN_ARGS_UNEVALLED (Lisp_Object) | ||
| 712 | #define DEFUN_ARGS_0 (void) | ||
| 713 | #define DEFUN_ARGS_1 (Lisp_Object) | ||
| 714 | #define DEFUN_ARGS_2 (Lisp_Object, Lisp_Object) | ||
| 715 | #define DEFUN_ARGS_3 (Lisp_Object, Lisp_Object, Lisp_Object) | ||
| 716 | #define DEFUN_ARGS_4 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object) | ||
| 717 | #define DEFUN_ARGS_5 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, \ | ||
| 718 | Lisp_Object) | ||
| 719 | #define DEFUN_ARGS_6 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, \ | ||
| 720 | Lisp_Object, Lisp_Object) | ||
| 721 | #define DEFUN_ARGS_7 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, \ | ||
| 722 | Lisp_Object, Lisp_Object, Lisp_Object) | ||
| 723 | #define DEFUN_ARGS_8 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, \ | ||
| 724 | Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object) | ||
| 725 | |||
| 726 | /* Yield an integer that contains TAG along with PTR. */ | ||
| 727 | #define TAG_PTR(tag, ptr) \ | ||
| 728 | ((USE_LSB_TAG ? (tag) : (EMACS_UINT) (tag) << VALBITS) + (uintptr_t) (ptr)) | ||
| 729 | |||
| 730 | /* Yield an integer that tags PTR as a symbol. */ | ||
| 731 | #define TAG_SYMPTR(ptr) \ | ||
| 732 | TAG_PTR (Lisp_Symbol, (char *) (ptr) - (char *) (USE_LSB_TAG ? lispsym : 0)) | ||
| 733 | |||
| 734 | /* Declare extern constants for Lisp symbols. These can be helpful | ||
| 735 | when using a debugger like GDB, on older platforms where the debug | ||
| 736 | format does not represent C macros. Athough these symbols are | ||
| 737 | useless on modern platforms, they don't hurt performance all that much. */ | ||
| 738 | #define DEFINE_LISP_SYMBOL_BEGIN(name) \ | ||
| 739 | DEFINE_GDB_SYMBOL_BEGIN (Lisp_Object, name) | ||
| 740 | #define DEFINE_LISP_SYMBOL_END(name) \ | ||
| 741 | DEFINE_GDB_SYMBOL_END (LISP_INITIALLY (TAG_SYMPTR (name))) | ||
| 742 | |||
| 743 | #include "globals.h" | ||
| 639 | 744 | ||
| 640 | /* Defined in xdisp.c. */ | ||
| 641 | extern Lisp_Object Qimage; | ||
| 642 | extern Lisp_Object Qfontification_functions; | ||
| 643 | |||
| 644 | /* Convert a Lisp_Object to the corresponding EMACS_INT and vice versa. | 745 | /* Convert a Lisp_Object to the corresponding EMACS_INT and vice versa. |
| 645 | At the machine level, these operations are no-ops. */ | 746 | At the machine level, these operations are no-ops. */ |
| 646 | LISP_MACRO_DEFUN (XLI, EMACS_INT, (Lisp_Object o), (o)) | 747 | LISP_MACRO_DEFUN (XLI, EMACS_INT, (Lisp_Object o), (o)) |
| @@ -728,6 +829,8 @@ LISP_MACRO_DEFUN (XINT, EMACS_INT, (Lisp_Object a), (a)) | |||
| 728 | LISP_MACRO_DEFUN (XFASTINT, EMACS_INT, (Lisp_Object a), (a)) | 829 | LISP_MACRO_DEFUN (XFASTINT, EMACS_INT, (Lisp_Object a), (a)) |
| 729 | LISP_MACRO_DEFUN (XTYPE, enum Lisp_Type, (Lisp_Object a), (a)) | 830 | LISP_MACRO_DEFUN (XTYPE, enum Lisp_Type, (Lisp_Object a), (a)) |
| 730 | LISP_MACRO_DEFUN (XUNTAG, void *, (Lisp_Object a, int type), (a, type)) | 831 | LISP_MACRO_DEFUN (XUNTAG, void *, (Lisp_Object a, int type), (a, type)) |
| 832 | LISP_MACRO_DEFUN (XUNTAGBASE, void *, (Lisp_Object a, int type, void *base), | ||
| 833 | (a, type, base)) | ||
| 731 | 834 | ||
| 732 | #else /* ! USE_LSB_TAG */ | 835 | #else /* ! USE_LSB_TAG */ |
| 733 | 836 | ||
| @@ -788,16 +891,21 @@ XTYPE (Lisp_Object a) | |||
| 788 | return USE_LSB_TAG ? i & ~VALMASK : i >> VALBITS; | 891 | return USE_LSB_TAG ? i & ~VALMASK : i >> VALBITS; |
| 789 | } | 892 | } |
| 790 | 893 | ||
| 894 | /* Extract A's pointer value, assuming A's type is TYPE. | ||
| 895 | If USE_LSB_TAG, add BASE to A's pointer value while extracting. */ | ||
| 896 | INLINE void * | ||
| 897 | XUNTAGBASE (Lisp_Object a, int type, void *base) | ||
| 898 | { | ||
| 899 | char *b = USE_LSB_TAG ? base : 0; | ||
| 900 | intptr_t i = USE_LSB_TAG ? XLI (a) - type : XLI (a) & VALMASK; | ||
| 901 | return b + i; | ||
| 902 | } | ||
| 903 | |||
| 791 | /* Extract A's pointer value, assuming A's type is TYPE. */ | 904 | /* Extract A's pointer value, assuming A's type is TYPE. */ |
| 792 | INLINE void * | 905 | INLINE void * |
| 793 | XUNTAG (Lisp_Object a, int type) | 906 | XUNTAG (Lisp_Object a, int type) |
| 794 | { | 907 | { |
| 795 | if (USE_LSB_TAG) | 908 | return XUNTAGBASE (a, type, 0); |
| 796 | { | ||
| 797 | intptr_t i = XLI (a) - type; | ||
| 798 | return (void *) i; | ||
| 799 | } | ||
| 800 | return XPNTR (a); | ||
| 801 | } | 909 | } |
| 802 | 910 | ||
| 803 | #endif /* ! USE_LSB_TAG */ | 911 | #endif /* ! USE_LSB_TAG */ |
| @@ -861,6 +969,10 @@ XSTRING (Lisp_Object a) | |||
| 861 | 969 | ||
| 862 | LISP_MACRO_DEFUN (XSYMBOL, struct Lisp_Symbol *, (Lisp_Object a), (a)) | 970 | LISP_MACRO_DEFUN (XSYMBOL, struct Lisp_Symbol *, (Lisp_Object a), (a)) |
| 863 | 971 | ||
| 972 | /* XSYMBOL_INIT (Qfoo) is like XSYMBOL (Qfoo), except it is valid in | ||
| 973 | static initializers, and SYM must be a C-defined symbol. */ | ||
| 974 | #define XSYMBOL_INIT(sym) a##sym | ||
| 975 | |||
| 864 | INLINE struct Lisp_Float * | 976 | INLINE struct Lisp_Float * |
| 865 | XFLOAT (Lisp_Object a) | 977 | XFLOAT (Lisp_Object a) |
| 866 | { | 978 | { |
| @@ -930,14 +1042,21 @@ XBOOL_VECTOR (Lisp_Object a) | |||
| 930 | INLINE Lisp_Object | 1042 | INLINE Lisp_Object |
| 931 | make_lisp_ptr (void *ptr, enum Lisp_Type type) | 1043 | make_lisp_ptr (void *ptr, enum Lisp_Type type) |
| 932 | { | 1044 | { |
| 933 | EMACS_UINT utype = type; | 1045 | Lisp_Object a = XIL (TAG_PTR (type, ptr)); |
| 934 | EMACS_UINT typebits = USE_LSB_TAG ? type : utype << VALBITS; | ||
| 935 | Lisp_Object a = XIL (typebits | (uintptr_t) ptr); | ||
| 936 | eassert (XTYPE (a) == type && XUNTAG (a, type) == ptr); | 1046 | eassert (XTYPE (a) == type && XUNTAG (a, type) == ptr); |
| 937 | return a; | 1047 | return a; |
| 938 | } | 1048 | } |
| 939 | 1049 | ||
| 940 | INLINE Lisp_Object | 1050 | INLINE Lisp_Object |
| 1051 | make_lisp_symbol (struct Lisp_Symbol *sym) | ||
| 1052 | { | ||
| 1053 | Lisp_Object a = XIL (TAG_SYMPTR (sym)); | ||
| 1054 | eassert (XTYPE (a) == Lisp_Symbol | ||
| 1055 | && XUNTAGBASE (a, Lisp_Symbol, lispsym) == sym); | ||
| 1056 | return a; | ||
| 1057 | } | ||
| 1058 | |||
| 1059 | INLINE Lisp_Object | ||
| 941 | make_lisp_proc (struct Lisp_Process *p) | 1060 | make_lisp_proc (struct Lisp_Process *p) |
| 942 | { | 1061 | { |
| 943 | return make_lisp_ptr (p, Lisp_Vectorlike); | 1062 | return make_lisp_ptr (p, Lisp_Vectorlike); |
| @@ -948,7 +1067,7 @@ make_lisp_proc (struct Lisp_Process *p) | |||
| 948 | #define XSETCONS(a, b) ((a) = make_lisp_ptr (b, Lisp_Cons)) | 1067 | #define XSETCONS(a, b) ((a) = make_lisp_ptr (b, Lisp_Cons)) |
| 949 | #define XSETVECTOR(a, b) ((a) = make_lisp_ptr (b, Lisp_Vectorlike)) | 1068 | #define XSETVECTOR(a, b) ((a) = make_lisp_ptr (b, Lisp_Vectorlike)) |
| 950 | #define XSETSTRING(a, b) ((a) = make_lisp_ptr (b, Lisp_String)) | 1069 | #define XSETSTRING(a, b) ((a) = make_lisp_ptr (b, Lisp_String)) |
| 951 | #define XSETSYMBOL(a, b) ((a) = make_lisp_ptr (b, Lisp_Symbol)) | 1070 | #define XSETSYMBOL(a, b) ((a) = make_lisp_symbol (b)) |
| 952 | #define XSETFLOAT(a, b) ((a) = make_lisp_ptr (b, Lisp_Float)) | 1071 | #define XSETFLOAT(a, b) ((a) = make_lisp_ptr (b, Lisp_Float)) |
| 953 | #define XSETMISC(a, b) ((a) = make_lisp_ptr (b, Lisp_Misc)) | 1072 | #define XSETMISC(a, b) ((a) = make_lisp_ptr (b, Lisp_Misc)) |
| 954 | 1073 | ||
| @@ -1555,72 +1674,6 @@ verify ((offsetof (struct Lisp_Sub_Char_Table, contents) | |||
| 1555 | Symbols | 1674 | Symbols |
| 1556 | ***********************************************************************/ | 1675 | ***********************************************************************/ |
| 1557 | 1676 | ||
| 1558 | /* Interned state of a symbol. */ | ||
| 1559 | |||
| 1560 | enum symbol_interned | ||
| 1561 | { | ||
| 1562 | SYMBOL_UNINTERNED = 0, | ||
| 1563 | SYMBOL_INTERNED = 1, | ||
| 1564 | SYMBOL_INTERNED_IN_INITIAL_OBARRAY = 2 | ||
| 1565 | }; | ||
| 1566 | |||
| 1567 | enum symbol_redirect | ||
| 1568 | { | ||
| 1569 | SYMBOL_PLAINVAL = 4, | ||
| 1570 | SYMBOL_VARALIAS = 1, | ||
| 1571 | SYMBOL_LOCALIZED = 2, | ||
| 1572 | SYMBOL_FORWARDED = 3 | ||
| 1573 | }; | ||
| 1574 | |||
| 1575 | struct Lisp_Symbol | ||
| 1576 | { | ||
| 1577 | bool_bf gcmarkbit : 1; | ||
| 1578 | |||
| 1579 | /* Indicates where the value can be found: | ||
| 1580 | 0 : it's a plain var, the value is in the `value' field. | ||
| 1581 | 1 : it's a varalias, the value is really in the `alias' symbol. | ||
| 1582 | 2 : it's a localized var, the value is in the `blv' object. | ||
| 1583 | 3 : it's a forwarding variable, the value is in `forward'. */ | ||
| 1584 | ENUM_BF (symbol_redirect) redirect : 3; | ||
| 1585 | |||
| 1586 | /* Non-zero means symbol is constant, i.e. changing its value | ||
| 1587 | should signal an error. If the value is 3, then the var | ||
| 1588 | can be changed, but only by `defconst'. */ | ||
| 1589 | unsigned constant : 2; | ||
| 1590 | |||
| 1591 | /* Interned state of the symbol. This is an enumerator from | ||
| 1592 | enum symbol_interned. */ | ||
| 1593 | unsigned interned : 2; | ||
| 1594 | |||
| 1595 | /* True means that this variable has been explicitly declared | ||
| 1596 | special (with `defvar' etc), and shouldn't be lexically bound. */ | ||
| 1597 | bool_bf declared_special : 1; | ||
| 1598 | |||
| 1599 | /* True if pointed to from purespace and hence can't be GC'd. */ | ||
| 1600 | bool_bf pinned : 1; | ||
| 1601 | |||
| 1602 | /* The symbol's name, as a Lisp string. */ | ||
| 1603 | Lisp_Object name; | ||
| 1604 | |||
| 1605 | /* Value of the symbol or Qunbound if unbound. Which alternative of the | ||
| 1606 | union is used depends on the `redirect' field above. */ | ||
| 1607 | union { | ||
| 1608 | Lisp_Object value; | ||
| 1609 | struct Lisp_Symbol *alias; | ||
| 1610 | struct Lisp_Buffer_Local_Value *blv; | ||
| 1611 | union Lisp_Fwd *fwd; | ||
| 1612 | } val; | ||
| 1613 | |||
| 1614 | /* Function value of the symbol or Qnil if not fboundp. */ | ||
| 1615 | Lisp_Object function; | ||
| 1616 | |||
| 1617 | /* The symbol's property list. */ | ||
| 1618 | Lisp_Object plist; | ||
| 1619 | |||
| 1620 | /* Next symbol in obarray bucket, if the symbol is interned. */ | ||
| 1621 | struct Lisp_Symbol *next; | ||
| 1622 | }; | ||
| 1623 | |||
| 1624 | /* Value is name of symbol. */ | 1677 | /* Value is name of symbol. */ |
| 1625 | 1678 | ||
| 1626 | LISP_MACRO_DEFUN (SYMBOL_VAL, Lisp_Object, (struct Lisp_Symbol *sym), (sym)) | 1679 | LISP_MACRO_DEFUN (SYMBOL_VAL, Lisp_Object, (struct Lisp_Symbol *sym), (sym)) |
| @@ -1694,8 +1747,9 @@ SYMBOL_INTERNED_IN_INITIAL_OBARRAY_P (Lisp_Object sym) | |||
| 1694 | 1747 | ||
| 1695 | LISP_MACRO_DEFUN (SYMBOL_CONSTANT_P, int, (Lisp_Object sym), (sym)) | 1748 | LISP_MACRO_DEFUN (SYMBOL_CONSTANT_P, int, (Lisp_Object sym), (sym)) |
| 1696 | 1749 | ||
| 1697 | #define DEFSYM(sym, name) \ | 1750 | /* Placeholder for make-docfile to process. The actual symbol |
| 1698 | do { (sym) = intern_c_string ((name)); staticpro (&(sym)); } while (false) | 1751 | definition is done by lread.c's defsym. */ |
| 1752 | #define DEFSYM(sym, name) /* empty */ | ||
| 1699 | 1753 | ||
| 1700 | 1754 | ||
| 1701 | /*********************************************************************** | 1755 | /*********************************************************************** |
| @@ -2689,24 +2743,6 @@ CHECK_NUMBER_CDR (Lisp_Object x) | |||
| 2689 | Lisp_Object fnname | 2743 | Lisp_Object fnname |
| 2690 | #endif | 2744 | #endif |
| 2691 | 2745 | ||
| 2692 | /* Note that the weird token-substitution semantics of ANSI C makes | ||
| 2693 | this work for MANY and UNEVALLED. */ | ||
| 2694 | #define DEFUN_ARGS_MANY (ptrdiff_t, Lisp_Object *) | ||
| 2695 | #define DEFUN_ARGS_UNEVALLED (Lisp_Object) | ||
| 2696 | #define DEFUN_ARGS_0 (void) | ||
| 2697 | #define DEFUN_ARGS_1 (Lisp_Object) | ||
| 2698 | #define DEFUN_ARGS_2 (Lisp_Object, Lisp_Object) | ||
| 2699 | #define DEFUN_ARGS_3 (Lisp_Object, Lisp_Object, Lisp_Object) | ||
| 2700 | #define DEFUN_ARGS_4 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object) | ||
| 2701 | #define DEFUN_ARGS_5 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, \ | ||
| 2702 | Lisp_Object) | ||
| 2703 | #define DEFUN_ARGS_6 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, \ | ||
| 2704 | Lisp_Object, Lisp_Object) | ||
| 2705 | #define DEFUN_ARGS_7 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, \ | ||
| 2706 | Lisp_Object, Lisp_Object, Lisp_Object) | ||
| 2707 | #define DEFUN_ARGS_8 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, \ | ||
| 2708 | Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object) | ||
| 2709 | |||
| 2710 | /* True if OBJ is a Lisp function. */ | 2746 | /* True if OBJ is a Lisp function. */ |
| 2711 | INLINE bool | 2747 | INLINE bool |
| 2712 | FUNCTIONP (Lisp_Object obj) | 2748 | FUNCTIONP (Lisp_Object obj) |
| @@ -3255,15 +3291,6 @@ extern int gcpro_level; | |||
| 3255 | 3291 | ||
| 3256 | void staticpro (Lisp_Object *); | 3292 | void staticpro (Lisp_Object *); |
| 3257 | 3293 | ||
| 3258 | /* Declare a Lisp-callable function. The MAXARGS parameter has the same | ||
| 3259 | meaning as in the DEFUN macro, and is used to construct a prototype. */ | ||
| 3260 | /* We can use the same trick as in the DEFUN macro to generate the | ||
| 3261 | appropriate prototype. */ | ||
| 3262 | #define EXFUN(fnname, maxargs) \ | ||
| 3263 | extern Lisp_Object fnname DEFUN_ARGS_ ## maxargs | ||
| 3264 | |||
| 3265 | #include "globals.h" | ||
| 3266 | |||
| 3267 | /* Forward declarations for prototypes. */ | 3294 | /* Forward declarations for prototypes. */ |
| 3268 | struct window; | 3295 | struct window; |
| 3269 | struct frame; | 3296 | struct frame; |
| @@ -3382,30 +3409,6 @@ set_sub_char_table_contents (Lisp_Object table, ptrdiff_t idx, Lisp_Object val) | |||
| 3382 | } | 3409 | } |
| 3383 | 3410 | ||
| 3384 | /* Defined in data.c. */ | 3411 | /* Defined in data.c. */ |
| 3385 | extern Lisp_Object Qquote, Qunbound; | ||
| 3386 | extern Lisp_Object Qerror_conditions, Qerror_message, Qtop_level; | ||
| 3387 | extern Lisp_Object Qerror, Qquit, Qargs_out_of_range; | ||
| 3388 | extern Lisp_Object Qvoid_variable, Qvoid_function; | ||
| 3389 | extern Lisp_Object Qinvalid_read_syntax; | ||
| 3390 | extern Lisp_Object Qinvalid_function, Qwrong_number_of_arguments, Qno_catch; | ||
| 3391 | extern Lisp_Object Quser_error, Qend_of_file, Qarith_error, Qmark_inactive; | ||
| 3392 | extern Lisp_Object Qbeginning_of_buffer, Qend_of_buffer, Qbuffer_read_only; | ||
| 3393 | extern Lisp_Object Qtext_read_only; | ||
| 3394 | extern Lisp_Object Qinteractive_form; | ||
| 3395 | extern Lisp_Object Qcircular_list; | ||
| 3396 | extern Lisp_Object Qsequencep; | ||
| 3397 | extern Lisp_Object Qchar_or_string_p, Qinteger_or_marker_p; | ||
| 3398 | extern Lisp_Object Qfboundp; | ||
| 3399 | |||
| 3400 | extern Lisp_Object Qcdr; | ||
| 3401 | |||
| 3402 | extern Lisp_Object Qrange_error, Qoverflow_error; | ||
| 3403 | |||
| 3404 | extern Lisp_Object Qnumber_or_marker_p; | ||
| 3405 | |||
| 3406 | extern Lisp_Object Qbuffer, Qinteger, Qsymbol; | ||
| 3407 | |||
| 3408 | /* Defined in data.c. */ | ||
| 3409 | extern Lisp_Object indirect_function (Lisp_Object); | 3412 | extern Lisp_Object indirect_function (Lisp_Object); |
| 3410 | extern Lisp_Object find_symbol_value (Lisp_Object); | 3413 | extern Lisp_Object find_symbol_value (Lisp_Object); |
| 3411 | enum Arith_Comparison { | 3414 | enum Arith_Comparison { |
| @@ -3461,7 +3464,6 @@ extern void syms_of_cmds (void); | |||
| 3461 | extern void keys_of_cmds (void); | 3464 | extern void keys_of_cmds (void); |
| 3462 | 3465 | ||
| 3463 | /* Defined in coding.c. */ | 3466 | /* Defined in coding.c. */ |
| 3464 | extern Lisp_Object Qcharset; | ||
| 3465 | extern Lisp_Object detect_coding_system (const unsigned char *, ptrdiff_t, | 3467 | extern Lisp_Object detect_coding_system (const unsigned char *, ptrdiff_t, |
| 3466 | ptrdiff_t, bool, bool, Lisp_Object); | 3468 | ptrdiff_t, bool, bool, Lisp_Object); |
| 3467 | extern void init_coding (void); | 3469 | extern void init_coding (void); |
| @@ -3485,14 +3487,10 @@ extern void init_syntax_once (void); | |||
| 3485 | extern void syms_of_syntax (void); | 3487 | extern void syms_of_syntax (void); |
| 3486 | 3488 | ||
| 3487 | /* Defined in fns.c. */ | 3489 | /* Defined in fns.c. */ |
| 3488 | extern Lisp_Object QCrehash_size, QCrehash_threshold; | ||
| 3489 | enum { NEXT_ALMOST_PRIME_LIMIT = 11 }; | 3490 | enum { NEXT_ALMOST_PRIME_LIMIT = 11 }; |
| 3490 | extern EMACS_INT next_almost_prime (EMACS_INT) ATTRIBUTE_CONST; | 3491 | extern EMACS_INT next_almost_prime (EMACS_INT) ATTRIBUTE_CONST; |
| 3491 | extern Lisp_Object larger_vector (Lisp_Object, ptrdiff_t, ptrdiff_t); | 3492 | extern Lisp_Object larger_vector (Lisp_Object, ptrdiff_t, ptrdiff_t); |
| 3492 | extern void sweep_weak_hash_tables (void); | 3493 | extern void sweep_weak_hash_tables (void); |
| 3493 | extern Lisp_Object Qcursor_in_echo_area; | ||
| 3494 | extern Lisp_Object Qstring_lessp; | ||
| 3495 | extern Lisp_Object QCsize, QCtest, QCweakness, Qequal, Qeq; | ||
| 3496 | EMACS_UINT hash_string (char const *, ptrdiff_t); | 3494 | EMACS_UINT hash_string (char const *, ptrdiff_t); |
| 3497 | EMACS_UINT sxhash (Lisp_Object, int); | 3495 | EMACS_UINT sxhash (Lisp_Object, int); |
| 3498 | Lisp_Object make_hash_table (struct hash_table_test, Lisp_Object, Lisp_Object, | 3496 | Lisp_Object make_hash_table (struct hash_table_test, Lisp_Object, Lisp_Object, |
| @@ -3532,15 +3530,11 @@ extern void init_fringe_once (void); | |||
| 3532 | #endif /* HAVE_WINDOW_SYSTEM */ | 3530 | #endif /* HAVE_WINDOW_SYSTEM */ |
| 3533 | 3531 | ||
| 3534 | /* Defined in image.c. */ | 3532 | /* Defined in image.c. */ |
| 3535 | extern Lisp_Object QCascent, QCmargin, QCrelief; | ||
| 3536 | extern Lisp_Object QCconversion; | ||
| 3537 | extern int x_bitmap_mask (struct frame *, ptrdiff_t); | 3533 | extern int x_bitmap_mask (struct frame *, ptrdiff_t); |
| 3538 | extern void reset_image_types (void); | 3534 | extern void reset_image_types (void); |
| 3539 | extern void syms_of_image (void); | 3535 | extern void syms_of_image (void); |
| 3540 | 3536 | ||
| 3541 | /* Defined in insdel.c. */ | 3537 | /* Defined in insdel.c. */ |
| 3542 | extern Lisp_Object Qinhibit_modification_hooks; | ||
| 3543 | extern Lisp_Object Qregion_extract_function; | ||
| 3544 | extern void move_gap_both (ptrdiff_t, ptrdiff_t); | 3538 | extern void move_gap_both (ptrdiff_t, ptrdiff_t); |
| 3545 | extern _Noreturn void buffer_overflow (void); | 3539 | extern _Noreturn void buffer_overflow (void); |
| 3546 | extern void make_gap (ptrdiff_t); | 3540 | extern void make_gap (ptrdiff_t); |
| @@ -3595,18 +3589,6 @@ extern Lisp_Object Vwindow_system; | |||
| 3595 | extern Lisp_Object sit_for (Lisp_Object, bool, int); | 3589 | extern Lisp_Object sit_for (Lisp_Object, bool, int); |
| 3596 | 3590 | ||
| 3597 | /* Defined in xdisp.c. */ | 3591 | /* Defined in xdisp.c. */ |
| 3598 | extern Lisp_Object Qinhibit_point_motion_hooks; | ||
| 3599 | extern Lisp_Object Qinhibit_redisplay; | ||
| 3600 | extern Lisp_Object Qmenu_bar_update_hook; | ||
| 3601 | extern Lisp_Object Qwindow_scroll_functions; | ||
| 3602 | extern Lisp_Object Qoverriding_local_map, Qoverriding_terminal_local_map; | ||
| 3603 | extern Lisp_Object Qtext, Qboth, Qboth_horiz, Qtext_image_horiz; | ||
| 3604 | extern Lisp_Object Qspace, Qcenter, QCalign_to; | ||
| 3605 | extern Lisp_Object Qbar, Qhbar, Qhollow; | ||
| 3606 | extern Lisp_Object Qleft_margin, Qright_margin; | ||
| 3607 | extern Lisp_Object QCdata, QCfile; | ||
| 3608 | extern Lisp_Object QCmap; | ||
| 3609 | extern Lisp_Object Qrisky_local_variable; | ||
| 3610 | extern bool noninteractive_need_newline; | 3592 | extern bool noninteractive_need_newline; |
| 3611 | extern Lisp_Object echo_area_buffer[2]; | 3593 | extern Lisp_Object echo_area_buffer[2]; |
| 3612 | extern void add_to_log (const char *, Lisp_Object, Lisp_Object); | 3594 | extern void add_to_log (const char *, Lisp_Object, Lisp_Object); |
| @@ -3740,8 +3722,6 @@ build_string (const char *str) | |||
| 3740 | 3722 | ||
| 3741 | extern Lisp_Object pure_cons (Lisp_Object, Lisp_Object); | 3723 | extern Lisp_Object pure_cons (Lisp_Object, Lisp_Object); |
| 3742 | extern void make_byte_code (struct Lisp_Vector *); | 3724 | extern void make_byte_code (struct Lisp_Vector *); |
| 3743 | extern Lisp_Object Qautomatic_gc; | ||
| 3744 | extern Lisp_Object Qchar_table_extra_slots; | ||
| 3745 | extern struct Lisp_Vector *allocate_vector (EMACS_INT); | 3725 | extern struct Lisp_Vector *allocate_vector (EMACS_INT); |
| 3746 | 3726 | ||
| 3747 | /* Make an uninitialized vector for SIZE objects. NOTE: you must | 3727 | /* Make an uninitialized vector for SIZE objects. NOTE: you must |
| @@ -3845,11 +3825,8 @@ extern void syms_of_chartab (void); | |||
| 3845 | /* Defined in print.c. */ | 3825 | /* Defined in print.c. */ |
| 3846 | extern Lisp_Object Vprin1_to_string_buffer; | 3826 | extern Lisp_Object Vprin1_to_string_buffer; |
| 3847 | extern void debug_print (Lisp_Object) EXTERNALLY_VISIBLE; | 3827 | extern void debug_print (Lisp_Object) EXTERNALLY_VISIBLE; |
| 3848 | extern Lisp_Object Qstandard_output; | ||
| 3849 | extern Lisp_Object Qexternal_debugging_output; | ||
| 3850 | extern void temp_output_buffer_setup (const char *); | 3828 | extern void temp_output_buffer_setup (const char *); |
| 3851 | extern int print_level; | 3829 | extern int print_level; |
| 3852 | extern Lisp_Object Qprint_escape_newlines; | ||
| 3853 | extern void write_string (const char *, int); | 3830 | extern void write_string (const char *, int); |
| 3854 | extern void print_error_message (Lisp_Object, Lisp_Object, const char *, | 3831 | extern void print_error_message (Lisp_Object, Lisp_Object, const char *, |
| 3855 | Lisp_Object); | 3832 | Lisp_Object); |
| @@ -3873,13 +3850,11 @@ extern ptrdiff_t evxprintf (char **, ptrdiff_t *, char const *, ptrdiff_t, | |||
| 3873 | ATTRIBUTE_FORMAT_PRINTF (5, 0); | 3850 | ATTRIBUTE_FORMAT_PRINTF (5, 0); |
| 3874 | 3851 | ||
| 3875 | /* Defined in lread.c. */ | 3852 | /* Defined in lread.c. */ |
| 3876 | extern Lisp_Object Qsize, Qvariable_documentation, Qstandard_input; | ||
| 3877 | extern Lisp_Object Qbackquote, Qcomma, Qcomma_at, Qcomma_dot, Qfunction; | ||
| 3878 | extern Lisp_Object Qlexical_binding; | ||
| 3879 | extern Lisp_Object check_obarray (Lisp_Object); | 3853 | extern Lisp_Object check_obarray (Lisp_Object); |
| 3880 | extern Lisp_Object intern_1 (const char *, ptrdiff_t); | 3854 | extern Lisp_Object intern_1 (const char *, ptrdiff_t); |
| 3881 | extern Lisp_Object intern_c_string_1 (const char *, ptrdiff_t); | 3855 | extern Lisp_Object intern_c_string_1 (const char *, ptrdiff_t); |
| 3882 | extern Lisp_Object intern_driver (Lisp_Object, Lisp_Object, ptrdiff_t); | 3856 | extern Lisp_Object intern_driver (Lisp_Object, Lisp_Object, Lisp_Object); |
| 3857 | extern void init_symbol (Lisp_Object, Lisp_Object); | ||
| 3883 | extern Lisp_Object oblookup (Lisp_Object, const char *, ptrdiff_t, ptrdiff_t); | 3858 | extern Lisp_Object oblookup (Lisp_Object, const char *, ptrdiff_t, ptrdiff_t); |
| 3884 | INLINE void | 3859 | INLINE void |
| 3885 | LOADHIST_ATTACH (Lisp_Object x) | 3860 | LOADHIST_ATTACH (Lisp_Object x) |
| @@ -3911,10 +3886,8 @@ intern_c_string (const char *str) | |||
| 3911 | 3886 | ||
| 3912 | /* Defined in eval.c. */ | 3887 | /* Defined in eval.c. */ |
| 3913 | extern EMACS_INT lisp_eval_depth; | 3888 | extern EMACS_INT lisp_eval_depth; |
| 3914 | extern Lisp_Object Qexit, Qinteractive, Qcommandp, Qmacro; | ||
| 3915 | extern Lisp_Object Qinhibit_quit, Qinternal_interpreter_environment, Qclosure; | ||
| 3916 | extern Lisp_Object Qand_rest; | ||
| 3917 | extern Lisp_Object Vautoload_queue; | 3889 | extern Lisp_Object Vautoload_queue; |
| 3890 | extern Lisp_Object Vrun_hooks; | ||
| 3918 | extern Lisp_Object Vsignaling_function; | 3891 | extern Lisp_Object Vsignaling_function; |
| 3919 | extern Lisp_Object inhibit_lisp_code; | 3892 | extern Lisp_Object inhibit_lisp_code; |
| 3920 | extern struct handler *handlerlist; | 3893 | extern struct handler *handlerlist; |
| @@ -3926,7 +3899,7 @@ extern struct handler *handlerlist; | |||
| 3926 | call1 (Vrun_hooks, Qmy_funny_hook); | 3899 | call1 (Vrun_hooks, Qmy_funny_hook); |
| 3927 | 3900 | ||
| 3928 | should no longer be used. */ | 3901 | should no longer be used. */ |
| 3929 | extern Lisp_Object Vrun_hooks; | 3902 | extern void run_hook (Lisp_Object); |
| 3930 | extern void run_hook_with_args_2 (Lisp_Object, Lisp_Object, Lisp_Object); | 3903 | extern void run_hook_with_args_2 (Lisp_Object, Lisp_Object, Lisp_Object); |
| 3931 | extern Lisp_Object run_hook_with_args (ptrdiff_t nargs, Lisp_Object *args, | 3904 | extern Lisp_Object run_hook_with_args (ptrdiff_t nargs, Lisp_Object *args, |
| 3932 | Lisp_Object (*funcall) | 3905 | Lisp_Object (*funcall) |
| @@ -3987,7 +3960,6 @@ extern bool let_shadows_global_binding_p (Lisp_Object symbol); | |||
| 3987 | 3960 | ||
| 3988 | 3961 | ||
| 3989 | /* Defined in editfns.c. */ | 3962 | /* Defined in editfns.c. */ |
| 3990 | extern Lisp_Object Qfield; | ||
| 3991 | extern void insert1 (Lisp_Object); | 3963 | extern void insert1 (Lisp_Object); |
| 3992 | extern Lisp_Object format2 (const char *, Lisp_Object, Lisp_Object); | 3964 | extern Lisp_Object format2 (const char *, Lisp_Object, Lisp_Object); |
| 3993 | extern Lisp_Object save_excursion_save (void); | 3965 | extern Lisp_Object save_excursion_save (void); |
| @@ -4034,12 +4006,6 @@ extern void syms_of_marker (void); | |||
| 4034 | 4006 | ||
| 4035 | /* Defined in fileio.c. */ | 4007 | /* Defined in fileio.c. */ |
| 4036 | 4008 | ||
| 4037 | extern Lisp_Object Qfile_error; | ||
| 4038 | extern Lisp_Object Qfile_notify_error; | ||
| 4039 | extern Lisp_Object Qfile_exists_p; | ||
| 4040 | extern Lisp_Object Qfile_directory_p; | ||
| 4041 | extern Lisp_Object Qinsert_file_contents; | ||
| 4042 | extern Lisp_Object Qfile_name_history; | ||
| 4043 | extern Lisp_Object expand_and_dir_to_file (Lisp_Object, Lisp_Object); | 4009 | extern Lisp_Object expand_and_dir_to_file (Lisp_Object, Lisp_Object); |
| 4044 | extern Lisp_Object write_region (Lisp_Object, Lisp_Object, Lisp_Object, | 4010 | extern Lisp_Object write_region (Lisp_Object, Lisp_Object, Lisp_Object, |
| 4045 | Lisp_Object, Lisp_Object, Lisp_Object, | 4011 | Lisp_Object, Lisp_Object, Lisp_Object, |
| @@ -4056,7 +4022,6 @@ extern bool file_accessible_directory_p (Lisp_Object); | |||
| 4056 | extern void init_fileio (void); | 4022 | extern void init_fileio (void); |
| 4057 | extern void syms_of_fileio (void); | 4023 | extern void syms_of_fileio (void); |
| 4058 | extern Lisp_Object make_temp_name (Lisp_Object, bool); | 4024 | extern Lisp_Object make_temp_name (Lisp_Object, bool); |
| 4059 | extern Lisp_Object Qdelete_file; | ||
| 4060 | 4025 | ||
| 4061 | /* Defined in search.c. */ | 4026 | /* Defined in search.c. */ |
| 4062 | extern void shrink_regexp_cache (void); | 4027 | extern void shrink_regexp_cache (void); |
| @@ -4086,7 +4051,6 @@ extern void clear_regexp_cache (void); | |||
| 4086 | 4051 | ||
| 4087 | /* Defined in minibuf.c. */ | 4052 | /* Defined in minibuf.c. */ |
| 4088 | 4053 | ||
| 4089 | extern Lisp_Object Qcompletion_ignore_case; | ||
| 4090 | extern Lisp_Object Vminibuffer_list; | 4054 | extern Lisp_Object Vminibuffer_list; |
| 4091 | extern Lisp_Object last_minibuf_string; | 4055 | extern Lisp_Object last_minibuf_string; |
| 4092 | extern Lisp_Object get_minibuffer (EMACS_INT); | 4056 | extern Lisp_Object get_minibuffer (EMACS_INT); |
| @@ -4095,15 +4059,10 @@ extern void syms_of_minibuf (void); | |||
| 4095 | 4059 | ||
| 4096 | /* Defined in callint.c. */ | 4060 | /* Defined in callint.c. */ |
| 4097 | 4061 | ||
| 4098 | extern Lisp_Object Qminus, Qplus; | ||
| 4099 | extern Lisp_Object Qprogn; | ||
| 4100 | extern Lisp_Object Qwhen; | ||
| 4101 | extern Lisp_Object Qmouse_leave_buffer_hook; | ||
| 4102 | extern void syms_of_callint (void); | 4062 | extern void syms_of_callint (void); |
| 4103 | 4063 | ||
| 4104 | /* Defined in casefiddle.c. */ | 4064 | /* Defined in casefiddle.c. */ |
| 4105 | 4065 | ||
| 4106 | extern Lisp_Object Qidentity; | ||
| 4107 | extern void syms_of_casefiddle (void); | 4066 | extern void syms_of_casefiddle (void); |
| 4108 | extern void keys_of_casefiddle (void); | 4067 | extern void keys_of_casefiddle (void); |
| 4109 | 4068 | ||
| @@ -4117,8 +4076,6 @@ extern void syms_of_casetab (void); | |||
| 4117 | extern Lisp_Object echo_message_buffer; | 4076 | extern Lisp_Object echo_message_buffer; |
| 4118 | extern struct kboard *echo_kboard; | 4077 | extern struct kboard *echo_kboard; |
| 4119 | extern void cancel_echoing (void); | 4078 | extern void cancel_echoing (void); |
| 4120 | extern Lisp_Object Qdisabled, QCfilter; | ||
| 4121 | extern Lisp_Object Qup, Qdown; | ||
| 4122 | extern Lisp_Object last_undo_boundary; | 4079 | extern Lisp_Object last_undo_boundary; |
| 4123 | extern bool input_pending; | 4080 | extern bool input_pending; |
| 4124 | #ifdef HAVE_STACK_OVERFLOW_HANDLING | 4081 | #ifdef HAVE_STACK_OVERFLOW_HANDLING |
| @@ -4152,7 +4109,6 @@ extern bool indented_beyond_p (ptrdiff_t, ptrdiff_t, EMACS_INT); | |||
| 4152 | extern void syms_of_indent (void); | 4109 | extern void syms_of_indent (void); |
| 4153 | 4110 | ||
| 4154 | /* Defined in frame.c. */ | 4111 | /* Defined in frame.c. */ |
| 4155 | extern Lisp_Object Qonly, Qnone; | ||
| 4156 | extern void store_frame_param (struct frame *, Lisp_Object, Lisp_Object); | 4112 | extern void store_frame_param (struct frame *, Lisp_Object, Lisp_Object); |
| 4157 | extern void store_in_alist (Lisp_Object *, Lisp_Object, Lisp_Object); | 4113 | extern void store_in_alist (Lisp_Object *, Lisp_Object, Lisp_Object); |
| 4158 | extern Lisp_Object do_switch_frame (Lisp_Object, int, int, Lisp_Object); | 4114 | extern Lisp_Object do_switch_frame (Lisp_Object, int, int, Lisp_Object); |
| @@ -4168,9 +4124,7 @@ extern bool display_arg; | |||
| 4168 | #endif | 4124 | #endif |
| 4169 | extern Lisp_Object decode_env_path (const char *, const char *, bool); | 4125 | extern Lisp_Object decode_env_path (const char *, const char *, bool); |
| 4170 | extern Lisp_Object empty_unibyte_string, empty_multibyte_string; | 4126 | extern Lisp_Object empty_unibyte_string, empty_multibyte_string; |
| 4171 | extern Lisp_Object Qfile_name_handler_alist; | ||
| 4172 | extern _Noreturn void terminate_due_to_signal (int, int); | 4127 | extern _Noreturn void terminate_due_to_signal (int, int); |
| 4173 | extern Lisp_Object Qkill_emacs; | ||
| 4174 | #ifdef WINDOWSNT | 4128 | #ifdef WINDOWSNT |
| 4175 | extern Lisp_Object Vlibrary_cache; | 4129 | extern Lisp_Object Vlibrary_cache; |
| 4176 | #endif | 4130 | #endif |
| @@ -4205,7 +4159,6 @@ extern bool inhibit_window_system; | |||
| 4205 | extern bool running_asynch_code; | 4159 | extern bool running_asynch_code; |
| 4206 | 4160 | ||
| 4207 | /* Defined in process.c. */ | 4161 | /* Defined in process.c. */ |
| 4208 | extern Lisp_Object QCtype, Qlocal; | ||
| 4209 | extern void kill_buffer_processes (Lisp_Object); | 4162 | extern void kill_buffer_processes (Lisp_Object); |
| 4210 | extern int wait_reading_process_output (intmax_t, int, int, bool, Lisp_Object, | 4163 | extern int wait_reading_process_output (intmax_t, int, int, bool, Lisp_Object, |
| 4211 | struct Lisp_Process *, int); | 4164 | struct Lisp_Process *, int); |
| @@ -4241,7 +4194,6 @@ extern void set_initial_environment (void); | |||
| 4241 | extern void syms_of_callproc (void); | 4194 | extern void syms_of_callproc (void); |
| 4242 | 4195 | ||
| 4243 | /* Defined in doc.c. */ | 4196 | /* Defined in doc.c. */ |
| 4244 | extern Lisp_Object Qfunction_documentation; | ||
| 4245 | extern Lisp_Object read_doc_string (Lisp_Object); | 4197 | extern Lisp_Object read_doc_string (Lisp_Object); |
| 4246 | extern Lisp_Object get_doc_string (Lisp_Object, bool, bool); | 4198 | extern Lisp_Object get_doc_string (Lisp_Object, bool, bool); |
| 4247 | extern void syms_of_doc (void); | 4199 | extern void syms_of_doc (void); |
| @@ -4262,8 +4214,6 @@ extern void init_macros (void); | |||
| 4262 | extern void syms_of_macros (void); | 4214 | extern void syms_of_macros (void); |
| 4263 | 4215 | ||
| 4264 | /* Defined in undo.c. */ | 4216 | /* Defined in undo.c. */ |
| 4265 | extern Lisp_Object Qapply; | ||
| 4266 | extern Lisp_Object Qinhibit_read_only; | ||
| 4267 | extern void truncate_undo_list (struct buffer *); | 4217 | extern void truncate_undo_list (struct buffer *); |
| 4268 | extern void record_insert (ptrdiff_t, ptrdiff_t); | 4218 | extern void record_insert (ptrdiff_t, ptrdiff_t); |
| 4269 | extern void record_delete (ptrdiff_t, Lisp_Object, bool); | 4219 | extern void record_delete (ptrdiff_t, Lisp_Object, bool); |
| @@ -4273,11 +4223,8 @@ extern void record_property_change (ptrdiff_t, ptrdiff_t, | |||
| 4273 | Lisp_Object, Lisp_Object, | 4223 | Lisp_Object, Lisp_Object, |
| 4274 | Lisp_Object); | 4224 | Lisp_Object); |
| 4275 | extern void syms_of_undo (void); | 4225 | extern void syms_of_undo (void); |
| 4276 | /* Defined in textprop.c. */ | ||
| 4277 | extern Lisp_Object Qmouse_face; | ||
| 4278 | extern Lisp_Object Qinsert_in_front_hooks, Qinsert_behind_hooks; | ||
| 4279 | extern Lisp_Object Qminibuffer_prompt; | ||
| 4280 | 4226 | ||
| 4227 | /* Defined in textprop.c. */ | ||
| 4281 | extern void report_interval_modification (Lisp_Object, Lisp_Object); | 4228 | extern void report_interval_modification (Lisp_Object, Lisp_Object); |
| 4282 | 4229 | ||
| 4283 | /* Defined in menu.c. */ | 4230 | /* Defined in menu.c. */ |
| @@ -4361,9 +4308,6 @@ extern void init_font (void); | |||
| 4361 | #ifdef HAVE_WINDOW_SYSTEM | 4308 | #ifdef HAVE_WINDOW_SYSTEM |
| 4362 | /* Defined in fontset.c. */ | 4309 | /* Defined in fontset.c. */ |
| 4363 | extern void syms_of_fontset (void); | 4310 | extern void syms_of_fontset (void); |
| 4364 | |||
| 4365 | /* Defined in xfns.c, w32fns.c, or macfns.c. */ | ||
| 4366 | extern Lisp_Object Qfont_param; | ||
| 4367 | #endif | 4311 | #endif |
| 4368 | 4312 | ||
| 4369 | /* Defined in gfilenotify.c */ | 4313 | /* Defined in gfilenotify.c */ |
| @@ -4383,16 +4327,6 @@ extern void syms_of_w32notify (void); | |||
| 4383 | #endif | 4327 | #endif |
| 4384 | 4328 | ||
| 4385 | /* Defined in xfaces.c. */ | 4329 | /* Defined in xfaces.c. */ |
| 4386 | extern Lisp_Object Qdefault, Qfringe; | ||
| 4387 | extern Lisp_Object Qscroll_bar, Qcursor; | ||
| 4388 | extern Lisp_Object Qmode_line_inactive; | ||
| 4389 | extern Lisp_Object Qface; | ||
| 4390 | extern Lisp_Object Qnormal; | ||
| 4391 | extern Lisp_Object QCfamily, QCweight, QCslant; | ||
| 4392 | extern Lisp_Object QCheight, QCname, QCwidth, QCforeground, QCbackground; | ||
| 4393 | extern Lisp_Object Qextra_light, Qlight, Qsemi_light, Qsemi_bold; | ||
| 4394 | extern Lisp_Object Qbold, Qextra_bold, Qultra_bold; | ||
| 4395 | extern Lisp_Object Qoblique, Qitalic; | ||
| 4396 | extern Lisp_Object Vface_alternative_font_family_alist; | 4330 | extern Lisp_Object Vface_alternative_font_family_alist; |
| 4397 | extern Lisp_Object Vface_alternative_font_registry_alist; | 4331 | extern Lisp_Object Vface_alternative_font_registry_alist; |
| 4398 | extern void syms_of_xfaces (void); | 4332 | extern void syms_of_xfaces (void); |