aboutsummaryrefslogtreecommitdiffstats
path: root/src/lisp.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lisp.h')
-rw-r--r--src/lisp.h37
1 files changed, 22 insertions, 15 deletions
diff --git a/src/lisp.h b/src/lisp.h
index 762d34abb9c..1e141dbb5d0 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -61,6 +61,23 @@ extern void check_cons_list (void);
61# define EMACS_UINT unsigned EMACS_INT 61# define EMACS_UINT unsigned EMACS_INT
62#endif 62#endif
63 63
64/* printmax_t and uprintmax_t are types for printing large integers.
65 These are the widest integers that are supported for printing.
66 pMd etc. are conversions for printing them.
67 On C99 hosts, there's no problem, as even the widest integers work.
68 Fall back on EMACS_INT on pre-C99 hosts. */
69#ifdef PRIdMAX
70typedef intmax_t printmax_t;
71typedef uintmax_t uprintmax_t;
72# define pMd PRIdMAX
73# define pMu PRIuMAX
74#else
75typedef EMACS_INT printmax_t;
76typedef EMACS_UINT uprintmax_t;
77# define pMd pI"d"
78# define pMu pI"u"
79#endif
80
64/* Use pD to format ptrdiff_t values, which suffice for indexes into 81/* Use pD to format ptrdiff_t values, which suffice for indexes into
65 buffers and strings. Emacs never allocates objects larger than 82 buffers and strings. Emacs never allocates objects larger than
66 PTRDIFF_MAX bytes, as they cause problems with pointer subtraction. 83 PTRDIFF_MAX bytes, as they cause problems with pointer subtraction.
@@ -833,7 +850,7 @@ struct Lisp_String
833 <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=8546>. */ 850 <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=8546>. */
834struct vectorlike_header 851struct vectorlike_header
835 { 852 {
836 EMACS_UINT size; 853 EMACS_INT size;
837 854
838 /* Pointer to the next vector-like object. It is generally a buffer or a 855 /* Pointer to the next vector-like object. It is generally a buffer or a
839 Lisp_Vector alias, so for convenience it is a union instead of a 856 Lisp_Vector alias, so for convenience it is a union instead of a
@@ -1028,7 +1045,7 @@ struct Lisp_Bool_Vector
1028 1045
1029struct Lisp_Subr 1046struct Lisp_Subr
1030 { 1047 {
1031 EMACS_UINT size; 1048 EMACS_INT size;
1032 union { 1049 union {
1033 Lisp_Object (*a0) (void); 1050 Lisp_Object (*a0) (void);
1034 Lisp_Object (*a1) (Lisp_Object); 1051 Lisp_Object (*a1) (Lisp_Object);
@@ -2540,6 +2557,7 @@ extern void sweep_weak_hash_tables (void);
2540extern Lisp_Object Qcursor_in_echo_area; 2557extern Lisp_Object Qcursor_in_echo_area;
2541extern Lisp_Object Qstring_lessp; 2558extern Lisp_Object Qstring_lessp;
2542extern Lisp_Object QCsize, QCtest, QCweakness, Qequal, Qeq, Qeql; 2559extern Lisp_Object QCsize, QCtest, QCweakness, Qequal, Qeq, Qeql;
2560EMACS_UINT hash_string (char const *, ptrdiff_t);
2543EMACS_UINT sxhash (Lisp_Object, int); 2561EMACS_UINT sxhash (Lisp_Object, int);
2544Lisp_Object make_hash_table (Lisp_Object, Lisp_Object, Lisp_Object, 2562Lisp_Object make_hash_table (Lisp_Object, Lisp_Object, Lisp_Object,
2545 Lisp_Object, Lisp_Object, Lisp_Object, 2563 Lisp_Object, Lisp_Object, Lisp_Object,
@@ -2868,7 +2886,8 @@ extern void float_to_string (char *, double);
2868extern void syms_of_print (void); 2886extern void syms_of_print (void);
2869 2887
2870/* Defined in doprnt.c */ 2888/* Defined in doprnt.c */
2871extern size_t doprnt (char *, size_t, const char *, const char *, va_list); 2889extern ptrdiff_t doprnt (char *, ptrdiff_t, const char *, const char *,
2890 va_list);
2872 2891
2873/* Defined in lread.c. */ 2892/* Defined in lread.c. */
2874extern Lisp_Object Qvariable_documentation, Qstandard_input; 2893extern Lisp_Object Qvariable_documentation, Qstandard_input;
@@ -3429,18 +3448,6 @@ extern EMACS_INT emacs_read (int, char *, EMACS_INT);
3429extern EMACS_INT emacs_write (int, const char *, EMACS_INT); 3448extern EMACS_INT emacs_write (int, const char *, EMACS_INT);
3430enum { READLINK_BUFSIZE = 1024 }; 3449enum { READLINK_BUFSIZE = 1024 };
3431extern char *emacs_readlink (const char *, char [READLINK_BUFSIZE]); 3450extern char *emacs_readlink (const char *, char [READLINK_BUFSIZE]);
3432#ifndef HAVE_MEMSET
3433extern void *memset (void *, int, size_t);
3434#endif
3435#ifndef HAVE_MEMCPY
3436extern void *memcpy (void *, void *, size_t);
3437#endif
3438#ifndef HAVE_MEMMOVE
3439extern void *memmove (void *, void *, size_t);
3440#endif
3441#ifndef HAVE_MEMCMP
3442extern int memcmp (void *, void *, size_t);
3443#endif
3444 3451
3445EXFUN (Funlock_buffer, 0); 3452EXFUN (Funlock_buffer, 0);
3446extern void unlock_all_files (void); 3453extern void unlock_all_files (void);