]> code.delx.au - gnu-emacs/commitdiff
* lisp.h (wrong_type_argument): Mark as NO_RETURN.
authorDan Nicolaescu <dann@ics.uci.edu>
Tue, 11 Apr 2006 07:13:33 +0000 (07:13 +0000)
committerDan Nicolaescu <dann@ics.uci.edu>
Tue, 11 Apr 2006 07:13:33 +0000 (07:13 +0000)
* data.c (wrong_type_argument): Try to avoid compiler warnings due
to the fact the function is now marked as NO_RETURN.

src/ChangeLog
src/data.c
src/lisp.h

index bd557cd0b169770f922238c207fd927b171598c4..936b14089b49335725b869aee4f9a8a2439ad248 100644 (file)
@@ -1,3 +1,10 @@
+2006-04-11  Dan Nicolaescu  <dann@ics.uci.edu>
+
+       * lisp.h (wrong_type_argument): Mark as NO_RETURN.
+
+       * data.c (wrong_type_argument): Try to avoid compiler warnings due
+       to the fact the function is now marked as NO_RETURN.
+
 2006-04-10  Eli Zaretskii  <eliz@gnu.org>
 
        * s/ms-w32.h (pid_t) [_MSC_VER]: New typedef.
index 73f712279d750eef520b506d29afb75de5da67b8..8b8015bb0027319fb6e900742681bc0edb2cb2d7 100644 (file)
@@ -125,7 +125,14 @@ wrong_type_argument (predicate, value)
       tem = call1 (predicate, value);
     }
   while (NILP (tem));
+  /* This function is marked as NO_RETURN, gcc would warn if it has a
+     return statement or if falls off the function.  Other compilers
+     warn if no return statement is present.  */
+#ifndef __GNUC__
   return value;
+#else
+  abort ();
+#endif
 }
 
 void
index 5d1b3266a0dd74147d6459280fc39203d51dd1d0..9748eebfcb5c7ea1474880720a8108b2f437c550 100644 (file)
@@ -2246,7 +2246,7 @@ extern unsigned long cons_to_long P_ ((Lisp_Object));
 extern void args_out_of_range P_ ((Lisp_Object, Lisp_Object)) NO_RETURN;
 extern void args_out_of_range_3 P_ ((Lisp_Object, Lisp_Object,
                                     Lisp_Object)) NO_RETURN;
-extern Lisp_Object wrong_type_argument P_ ((Lisp_Object, Lisp_Object));
+extern Lisp_Object wrong_type_argument P_ ((Lisp_Object, Lisp_Object)) NO_RETURN;
 extern void store_symval_forwarding P_ ((Lisp_Object, Lisp_Object,
                                         Lisp_Object, struct buffer *));
 extern Lisp_Object do_symval_forwarding P_ ((Lisp_Object));