aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorStefan Monnier2010-07-20 17:26:53 +0200
committerStefan Monnier2010-07-20 17:26:53 +0200
commitd5273788df4b8e6f4a266bfac3fd63ac10265dc7 (patch)
tree8aa8e0aed73a0d937d4a244d85523a06b1fe4eba /src
parenta628ad9d974d15b9fbab527e0151377d23b5aeae (diff)
downloademacs-d5273788df4b8e6f4a266bfac3fd63ac10265dc7.tar.gz
emacs-d5273788df4b8e6f4a266bfac3fd63ac10265dc7.zip
Fix up "missing braces" warning.
* src/eval.c (Feval, Ffuncall): Use the new names. * src/lisp.h (struct Lisp_Subr): Rename `am' to aMANY and add aUNEVALLED. (DEFUN): Add braces around the union initialisation and use ## to specify the right union alternative and avoid a cast.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog8
-rw-r--r--src/eval.c6
-rw-r--r--src/lisp.h6
3 files changed, 15 insertions, 5 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 43b4c08dd23..81b4560e06d 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,11 @@
12010-07-20 Stefan Monnier <monnier@iro.umontreal.ca>
2
3 * eval.c (Feval, Ffuncall): Use the new names.
4
5 * lisp.h (struct Lisp_Subr): Rename `am' to aMANY and add aUNEVALLED.
6 (DEFUN): Add braces around the union initialisation and use ## to
7 specify the right union alternative and avoid a cast.
8
12010-07-18 Juanma Barranquero <lekktu@gmail.com> 92010-07-18 Juanma Barranquero <lekktu@gmail.com>
2 10
3 * makefile.w32-in ($(BLD)/keyboard.$(O)): Update dependencies. 11 * makefile.w32-in ($(BLD)/keyboard.$(O)): Update dependencies.
diff --git a/src/eval.c b/src/eval.c
index 953a41e4b1e..06888ca0dd4 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -2299,7 +2299,7 @@ DEFUN ("eval", Feval, Seval, 1, 1, 0,
2299 if (XSUBR (fun)->max_args == UNEVALLED) 2299 if (XSUBR (fun)->max_args == UNEVALLED)
2300 { 2300 {
2301 backtrace.evalargs = 0; 2301 backtrace.evalargs = 0;
2302 val = (XSUBR (fun)->function.a1) (args_left); 2302 val = (XSUBR (fun)->function.aUNEVALLED) (args_left);
2303 goto done; 2303 goto done;
2304 } 2304 }
2305 2305
@@ -2325,7 +2325,7 @@ DEFUN ("eval", Feval, Seval, 1, 1, 0,
2325 backtrace.args = vals; 2325 backtrace.args = vals;
2326 backtrace.nargs = XINT (numargs); 2326 backtrace.nargs = XINT (numargs);
2327 2327
2328 val = (XSUBR (fun)->function.am) (XINT (numargs), vals); 2328 val = (XSUBR (fun)->function.aMANY) (XINT (numargs), vals);
2329 UNGCPRO; 2329 UNGCPRO;
2330 goto done; 2330 goto done;
2331 } 2331 }
@@ -2968,7 +2968,7 @@ usage: (funcall FUNCTION &rest ARGUMENTS) */)
2968 2968
2969 if (XSUBR (fun)->max_args == MANY) 2969 if (XSUBR (fun)->max_args == MANY)
2970 { 2970 {
2971 val = (XSUBR (fun)->function.am) (numargs, args + 1); 2971 val = (XSUBR (fun)->function.aMANY) (numargs, args + 1);
2972 goto done; 2972 goto done;
2973 } 2973 }
2974 2974
diff --git a/src/lisp.h b/src/lisp.h
index 3ec2ed07ed9..d1a14fcd894 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -971,7 +971,8 @@ struct Lisp_Subr
971 Lisp_Object (*a6) (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object); 971 Lisp_Object (*a6) (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object);
972 Lisp_Object (*a7) (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object); 972 Lisp_Object (*a7) (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object);
973 Lisp_Object (*a8) (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object); 973 Lisp_Object (*a8) (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object);
974 Lisp_Object (*am) (int, Lisp_Object *); 974 Lisp_Object (*aUNEVALLED) (Lisp_Object args);
975 Lisp_Object (*aMANY) (int, Lisp_Object *);
975 } function; 976 } function;
976 short min_args, max_args; 977 short min_args, max_args;
977 const char *symbol_name; 978 const char *symbol_name;
@@ -1775,7 +1776,8 @@ typedef struct {
1775 Lisp_Object fnname DEFUN_ARGS_ ## maxargs ; \ 1776 Lisp_Object fnname DEFUN_ARGS_ ## maxargs ; \
1776 DECL_ALIGN (struct Lisp_Subr, sname) = \ 1777 DECL_ALIGN (struct Lisp_Subr, sname) = \
1777 { PVEC_SUBR | (sizeof (struct Lisp_Subr) / sizeof (EMACS_INT)), \ 1778 { PVEC_SUBR | (sizeof (struct Lisp_Subr) / sizeof (EMACS_INT)), \
1778 (Lisp_Object(*)(void)) fnname, minargs, maxargs, lname, intspec, 0}; \ 1779 { .a ## maxargs = fnname }, \
1780 minargs, maxargs, lname, intspec, 0}; \
1779 Lisp_Object fnname 1781 Lisp_Object fnname
1780 1782
1781/* Note that the weird token-substitution semantics of ANSI C makes 1783/* Note that the weird token-substitution semantics of ANSI C makes