changeset 21514:fa9ff387d260

Fix -Wimplicit warnings.
author Andreas Schwab <schwab@suse.de>
date Tue, 14 Apr 1998 12:25:56 +0000
parents 984881b316fc
children fb4c986db0e2
files src/abbrev.c src/alloc.c src/buffer.c src/bytecode.c src/callint.c src/callproc.c src/casefiddle.c src/casetab.c src/category.c src/ccl.c src/charset.c src/cm.c src/cmds.c src/coding.c src/data.c src/dired.c src/dispnew.c src/doc.c src/doprnt.c src/editfns.c src/emacs.c src/eval.c src/fileio.c src/filelock.c src/floatfns.c src/fns.c src/fontset.c src/frame.c src/indent.c src/insdel.c src/intervals.c src/keyboard.c src/keymap.c src/marker.c src/mocklisp.c src/prefix-args.c src/print.c src/process.c src/scroll.c src/search.c src/syntax.c src/sysdep.c src/term.c src/terminfo.c src/undo.c src/widget.c src/window.c src/xdisp.c src/xmenu.c src/xrdb.c src/xselect.c src/xterm.c
diffstat 52 files changed, 394 insertions(+), 94 deletions(-) [+]
line wrap: on
line diff
--- a/src/abbrev.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/abbrev.c	Tue Apr 14 12:25:56 1998 +0000
@@ -517,6 +517,7 @@
   return Qnil;
 }
 
+void
 syms_of_abbrev ()
 {
   DEFVAR_LISP ("abbrev-table-name-list", &Vabbrev_table_name_list,
--- a/src/alloc.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/alloc.c	Tue Apr 14 12:25:56 1998 +0000
@@ -593,6 +593,7 @@
 }
 
 /* Explicitly free a float cell.  */
+void
 free_float (ptr)
      struct Lisp_Float *ptr;
 {
@@ -2947,6 +2948,7 @@
 
 /* Initialization */
 
+void
 init_alloc_once ()
 {
   /* Used to do Vpurify_flag = Qt here, but Qt isn't set up yet!  */
@@ -2989,6 +2991,7 @@
 #endif /* VIRT_ADDR_VARIES */
 }
 
+void
 init_alloc ()
 {
   gcprolist = 0;
--- a/src/buffer.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/buffer.c	Tue Apr 14 12:25:56 1998 +0000
@@ -33,6 +33,12 @@
 #endif /* not MAXPATHLEN */
 
 #include <config.h>
+#ifdef STDC_HEADERS
+#include <stdlib.h>
+#endif
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
 #include "lisp.h"
 #include "intervals.h"
 #include "window.h"
@@ -2230,9 +2236,11 @@
 };
 
 static int
-compare_overlays (s1, s2)
-     struct sortvec *s1, *s2;
+compare_overlays (v1, v2)
+     const void *v1, *v2;
 {
+  const struct sortvec *s1 = (const struct sortvec *) v1;
+  const struct sortvec *s2 = (const struct sortvec *) v2;
   if (s1->priority != s2->priority)
     return s1->priority - s2->priority;
   if (s1->beg != s2->beg)
@@ -3773,6 +3781,7 @@
 	 type_name, XSYMBOL (sym)->name->data);
 }
 
+void
 init_buffer_once ()
 {
   register Lisp_Object tem;
@@ -3914,6 +3923,7 @@
   Fset_buffer (Fget_buffer_create (build_string ("*scratch*")));
 }
 
+void
 init_buffer ()
 {
   char buf[MAXPATHLEN+1];
@@ -3973,6 +3983,7 @@
 }
 
 /* initialize the buffer routines */
+void
 syms_of_buffer ()
 {
   extern Lisp_Object Qdisabled;
@@ -4553,6 +4564,7 @@
   defsubr (&Soverlay_put);
 }
 
+void
 keys_of_buffer ()
 {
   initial_define_key (control_x_map, 'b', "switch-to-buffer");
--- a/src/bytecode.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/bytecode.c	Tue Apr 14 12:25:56 1998 +0000
@@ -1159,6 +1159,7 @@
   return v1;
 }
 
+void
 syms_of_bytecode ()
 {
   Qbytecode = intern ("byte-code");
--- a/src/callint.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/callint.c	Tue Apr 14 12:25:56 1998 +0000
@@ -772,6 +772,7 @@
   return val;
 }
 
+void
 syms_of_callint ()
 {
   point_marker = Fmake_marker ();
--- a/src/callproc.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/callproc.c	Tue Apr 14 12:25:56 1998 +0000
@@ -914,6 +914,8 @@
 
 #ifndef VMS /* VMS version is in vmsproc.c.  */
 
+static int relocate_fd ();
+
 /* This is the last thing run in a newly forked inferior
    either synchronous or asynchronous.
    Copy descriptors IN, OUT and ERR as descriptors 0, 1 and 2.
@@ -934,6 +936,7 @@
    a decent error from within the child, this should be verified as an
    executable directory by the parent.  */
 
+int
 child_setup (in, out, err, new_argv, set_pgrp, current_dir)
      int in, out, err;
      register char **new_argv;
@@ -1130,7 +1133,7 @@
 
 /* Move the file descriptor FD so that its number is not less than MINFD.
    If the file descriptor is moved at all, the original is freed.  */
-int
+static int
 relocate_fd (fd, minfd)
      int fd, minfd;
 {
@@ -1228,6 +1231,7 @@
 
 /* This is run before init_cmdargs.  */
   
+void
 init_callproc_1 ()
 {
   char *data_dir = egetenv ("EMACSDATA");
@@ -1249,6 +1253,7 @@
 
 /* This is run after init_cmdargs, when Vinstallation_directory is valid.  */
 
+void
 init_callproc ()
 {
   char *data_dir = egetenv ("EMACSDATA");
@@ -1341,6 +1346,7 @@
 #endif
 }
 
+void
 set_process_environment ()
 {
   register char **envp;
@@ -1354,6 +1360,7 @@
 				    Vprocess_environment);
 }
 
+void
 syms_of_callproc ()
 {
 #ifdef DOS_NT
--- a/src/casefiddle.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/casefiddle.c	Tue Apr 14 12:25:56 1998 +0000
@@ -182,6 +182,7 @@
 /* flag is CASE_UP, CASE_DOWN or CASE_CAPITALIZE or CASE_CAPITALIZE_UP.
    b and e specify range of buffer to operate on. */
 
+void
 casify_region (flag, b, e)
      enum case_action flag;
      Lisp_Object b, e;
@@ -404,6 +405,7 @@
   return Qnil;
 }
 
+void
 syms_of_casefiddle ()
 {
   Qidentity = intern ("identity");
@@ -421,6 +423,7 @@
   defsubr (&Scapitalize_word);
 }
 
+void
 keys_of_casefiddle ()
 {
   initial_define_key (control_x_map, Ctl('U'), "upcase-region");
--- a/src/casetab.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/casetab.c	Tue Apr 14 12:25:56 1998 +0000
@@ -216,6 +216,7 @@
     }
 }
 
+void
 init_casetab_once ()
 {
   register int i;
@@ -256,6 +257,7 @@
   XCHAR_TABLE (down)->extras[2] = Fcopy_sequence (up);
 }
 
+void
 syms_of_casetab ()
 {
   Qcase_table_p = intern ("case-table-p");
--- a/src/category.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/category.c	Tue Apr 14 12:25:56 1998 +0000
@@ -601,6 +601,7 @@
 }
 
 
+void
 init_category_once ()
 {
   /* This has to be done here, before we call Fmake_char_table.  */
@@ -623,6 +624,7 @@
 			      Fmake_vector (make_number (95), Qnil));
 }
 
+void
 syms_of_category ()
 {
   Qcategoryp = intern ("categoryp");
--- a/src/ccl.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/ccl.c	Tue Apr 14 12:25:56 1998 +0000
@@ -24,6 +24,11 @@
 #ifdef emacs
 
 #include <config.h>
+
+#ifdef STDC_HEADERS
+#include <stdlib.h>
+#endif
+
 #include "lisp.h"
 #include "charset.h"
 #include "ccl.h"
@@ -659,6 +664,7 @@
     int ic;			/* Instruction Counter.  */
   };
 
+int
 ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
      struct ccl_program *ccl;
      unsigned char *source, *destination;
@@ -1699,6 +1705,7 @@
 }
 
 
+void
 syms_of_ccl ()
 {
   staticpro (&Vccl_program_table);
--- a/src/charset.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/charset.c	Tue Apr 14 12:25:56 1998 +0000
@@ -173,6 +173,7 @@
    Use macro `STRING_CHAR (STR, LEN)' instead of calling this function
    directly if STR can hold an ASCII character.  */
 
+int
 string_to_non_ascii_char (str, len, actual_len)
      const unsigned char *str;
      int len, *actual_len;
@@ -237,6 +238,7 @@
    return -1.  This should be used only in the macro SPLIT_STRING
    which checks range of STR in advance.  */
 
+int
 split_non_ascii_string (str, len, charset, c1, c2)
      register const unsigned char *str;
      register unsigned char *c1, *c2;
@@ -274,6 +276,7 @@
 /* Return a character unified with C (or a character made of CHARSET,
    C1, and C2) in unification table TABLE.  If no unification is found
    in TABLE, return C.  */
+int
 unify_char (table, c, charset, c1, c2)
      Lisp_Object table;
      int c, charset, c1, c2;
@@ -308,6 +311,7 @@
    convert C to a valid multibyte character, convert it based on
    DEFAULT_NONASCII_INSERT_OFFSET which makes C a Latin-1 character.  */
 
+int
 unibyte_char_to_multibyte (c)
      int c;
 {
@@ -1610,6 +1614,7 @@
 }
 
 
+int
 charset_id_internal (charset_name)
      char *charset_name;
 {
@@ -1635,6 +1640,7 @@
   return Qnil;
 }
 
+void
 init_charset_once ()
 {
   int i, j, k;
@@ -1689,6 +1695,7 @@
 
 #ifdef emacs
 
+void
 syms_of_charset ()
 {
   Qascii = intern ("ascii");
--- a/src/cm.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/cm.c	Tue Apr 14 12:25:56 1998 +0000
@@ -35,6 +35,7 @@
 int cost;		/* sums up costs */
 
 /* ARGSUSED */
+int
 evalcost (c)
      char c;
 {
@@ -42,6 +43,7 @@
   return c;
 }
 
+int
 cmputc (c)
      char c;
 {
@@ -135,6 +137,7 @@
  * out of <sgtty.h>.)
  */
 
+void
 cmcostinit ()
 {
     char *p;
@@ -174,7 +177,7 @@
  * actually perform the motion.
  */
 
-static
+static int
 calccost (srcy, srcx, dsty, dstx, doit)
 {
     register int    deltay,
@@ -309,6 +312,7 @@
 #define	USELL	2
 #define	USECR	3
 
+void
 cmgoto (row, col)
 {
     int     homecost,
@@ -411,6 +415,7 @@
    Used before copying into it the info on the actual terminal.
  */
 
+void
 Wcm_clear ()
 {
   bzero (&Wcm, sizeof Wcm);
@@ -425,6 +430,7 @@
  * Return -2 if size not specified.
  */
 
+int
 Wcm_init ()
 {
 #if 0
--- a/src/cmds.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/cmds.c	Tue Apr 14 12:25:56 1998 +0000
@@ -27,6 +27,7 @@
 #include "syntax.h"
 #include "window.h"
 #include "keyboard.h"
+#include "dispextern.h"
 
 Lisp_Object Qkill_forward_chars, Qkill_backward_chars, Vblink_paren_function;
 
@@ -326,6 +327,7 @@
    return 0.  A value of 1 indicates this *might* not have been simple.
    A value of 2 means this did things that call for an undo boundary.  */
 
+int
 internal_self_insert (c, noautofill)
      int c;
      int noautofill;
@@ -503,6 +505,7 @@
 
 /* module initialization */
 
+void
 syms_of_cmds ()
 {
   Qkill_backward_chars = intern ("kill-backward-chars");
@@ -542,6 +545,7 @@
   defsubr (&Sself_insert_command);
 }
 
+void
 keys_of_cmds ()
 {
   int n;
--- a/src/coding.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/coding.c	Tue Apr 14 12:25:56 1998 +0000
@@ -1681,6 +1681,7 @@
    If the current block ends before any end-of-line, we may fail to
    find all the necessary designations.  */
 
+void
 encode_designation_at_bol (coding, table, src, src_end, dstp)
      struct coding_system *coding;
      Lisp_Object table;
@@ -2465,6 +2466,7 @@
    This function is called only when `coding->eol_type' is
    CODING_EOL_CRLF or CODING_EOL_CR.  */
 
+int
 decode_eol (coding, source, destination, src_bytes, dst_bytes)
      struct coding_system *coding;
      unsigned char *source, *destination;
@@ -2595,6 +2597,7 @@
    `coding->mode & CODING_MODE_SELECTIVE_DISPLAY' is nonzero, code
    '\r' in source text also means end-of-line.  */
 
+int
 encode_eol (coding, source, destination, src_bytes, dst_bytes)
      struct coding_system *coding;
      unsigned char *source, *destination;
@@ -4941,6 +4944,7 @@
 
 /*** 8. Post-amble ***/
 
+void
 init_coding_once ()
 {
   int i;
@@ -4999,6 +5003,7 @@
 
 #ifdef emacs
 
+void
 syms_of_coding ()
 {
   Qtarget_idx = intern ("target-idx");
--- a/src/data.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/data.c	Tue Apr 14 12:25:56 1998 +0000
@@ -136,6 +136,7 @@
   return value;
 }
 
+void
 pure_write_error ()
 {
   error ("Attempt to modify read-only object");
@@ -2957,6 +2958,7 @@
   Fsignal (Qarith_error, Qnil);
 }
 
+void
 init_data ()
 {
   /* Don't do this if just dumping out.
--- a/src/dired.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/dired.c	Tue Apr 14 12:25:56 1998 +0000
@@ -31,6 +31,10 @@
 #include <rmsdef.h>
 #endif
 
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+
 /* The d_nameln member of a struct dirent includes the '\0' character
    on some systems, but not on others.  What's worse, you can't tell
    at compile-time which one it will be, since it really depends on
@@ -295,6 +299,8 @@
   return file_name_completion (file, directory, 1, 0);
 }
 
+static int file_name_completion_stat ();
+
 Lisp_Object
 file_name_completion (file, dirname, all_flag, ver_flag)
      Lisp_Object file, dirname;
@@ -547,6 +553,7 @@
   return Fsignal (Qquit, Qnil);
 }
 
+static int
 file_name_completion_stat (dirname, dp, st_addr)
      Lisp_Object dirname;
      DIRENTRY *dp;
@@ -742,6 +749,7 @@
   return Flist (sizeof(values) / sizeof(values[0]), values);
 }
 
+void
 syms_of_dired ()
 {
   Qdirectory_files = intern ("directory-files");
--- a/src/dispnew.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/dispnew.c	Tue Apr 14 12:25:56 1998 +0000
@@ -27,6 +27,10 @@
 #include <stdio.h>
 #include <ctype.h>
 
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+
 #include "lisp.h"
 #include "termchar.h"
 #include "termopts.h"
@@ -43,6 +47,8 @@
 #include "indent.h"
 #include "intervals.h"
 #include "blockinput.h"
+#include "process.h"
+#include "keyboard.h"
 
 /* I don't know why DEC Alpha OSF1 fail to compile this file if we
    include the following file.  */
@@ -187,6 +193,7 @@
   return Qnil;
 }
 
+void
 redraw_frame (f)
      FRAME_PTR f;
 {
@@ -229,8 +236,8 @@
      int empty;
 {
   register int i;
-  register width = FRAME_WINDOW_WIDTH (frame);
-  register height = FRAME_HEIGHT (frame);
+  register int width = FRAME_WINDOW_WIDTH (frame);
+  register int height = FRAME_HEIGHT (frame);
   register struct frame_glyphs *new
     = (struct frame_glyphs *) xmalloc (sizeof (struct frame_glyphs));
 
@@ -468,6 +475,7 @@
 
 /* cancel_line eliminates any request to display a line at position `vpos' */
 
+void
 cancel_line (vpos, frame)
      int vpos;
      register FRAME_PTR frame;
@@ -475,6 +483,7 @@
   FRAME_DESIRED_GLYPHS (frame)->enable[vpos] = 0;
 }
 
+void
 clear_frame_records (frame)
      register FRAME_PTR frame;
 {
@@ -823,6 +832,7 @@
    into the FRAME_DESIRED_GLYPHS (frame) from the FRAME_PHYS_GLYPHS (frame)
    so that update_frame will not change those columns.  */
 
+void
 preserve_other_columns (w)
      struct window *w;
 {
@@ -947,6 +957,7 @@
    for internal consistency.  We cannot check that they are "right";
    we can only look for something nonsensical.  */
 
+void
 verify_charstarts (w)
      struct window *w;
 {
@@ -1003,6 +1014,7 @@
    cancel the columns of that window, so that when the window is
    displayed over again get_display_line will not complain.  */
 
+void
 cancel_my_columns (w)
      struct window *w;
 {
@@ -1198,7 +1210,7 @@
   register int i;
   int pause;
   int preempt_count = baud_rate / 2400 + 1;
-  extern input_pending;
+  extern int input_pending;
 #ifdef HAVE_WINDOW_SYSTEM
   register int downto, leftmost;
 #endif
@@ -1398,6 +1410,7 @@
 
 extern void scrolling_1 ();
 
+int
 scrolling (frame)
      FRAME_PTR frame;
 {
@@ -1831,7 +1844,7 @@
 	  olen = nlen - (nsp - osp);
 	}
       cursor_to (vpos, osp);
-      insert_glyphs ((char *)0, nsp - osp);
+      insert_glyphs ((GLYPH *) 0, nsp - osp);
     }
   olen += nsp - osp;
 
@@ -2070,6 +2083,7 @@
 
 /* Do any change in frame size that was requested by a signal.  */
 
+void
 do_pending_window_change ()
 {
   /* If window_change_signal should have run before, run it now.  */
@@ -2101,9 +2115,10 @@
    redisplay.  Since this tries to resize windows, we can't call it
    from a signal handler.  */
 
+void
 change_frame_size (f, newheight, newwidth, pretend, delay)
      register FRAME_PTR f;
-     int newheight, newwidth, pretend;
+     int newheight, newwidth, pretend, delay;
 {
   Lisp_Object tail, frame;
 
@@ -2284,6 +2299,7 @@
   return Qnil;
 }
 
+void
 bitch_at_user ()
 {
   if (noninteractive)
@@ -2469,6 +2485,7 @@
 /* Then invoke its decoding routine to set up variables
   in the terminal package */
 
+void
 init_display ()
 {
 #ifdef HAVE_X_WINDOWS
@@ -2604,6 +2621,7 @@
 #endif /* SIGWINCH */
 }
 
+void
 syms_of_display ()
 {
   defsubr (&Sredraw_frame);
--- a/src/doc.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/doc.c	Tue Apr 14 12:25:56 1998 +0000
@@ -737,6 +737,7 @@
   RETURN_UNGCPRO (tem);
 }
 
+void
 syms_of_doc ()
 {
   DEFVAR_LISP ("internal-doc-file-name", &Vdoc_file_name,
--- a/src/doprnt.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/doprnt.c	Tue Apr 14 12:25:56 1998 +0000
@@ -54,6 +54,7 @@
    String arguments are passed as C strings.
    Integers are passed as C integers.  */
 
+int
 doprnt (buffer, bufsize, format, format_end, nargs, args)
      char *buffer;
      register int bufsize;
@@ -68,6 +69,7 @@
 /* Like doprnt except that strings in ARGS are passed
    as Lisp_Object.  */
 
+int
 doprnt_lisp (buffer, bufsize, format, format_end, nargs, args)
      char *buffer;
      register int bufsize;
--- a/src/editfns.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/editfns.c	Tue Apr 14 12:25:56 1998 +0000
@@ -29,6 +29,14 @@
 #include <pwd.h>
 #endif
 
+#ifdef STDC_HEADERS
+#include <stdlib.h>
+#endif
+
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+
 #include "lisp.h"
 #include "intervals.h"
 #include "buffer.h"
--- a/src/emacs.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/emacs.c	Tue Apr 14 12:25:56 1998 +0000
@@ -44,6 +44,7 @@
 #include "blockinput.h"
 #include "syssignal.h"
 #include "process.h"
+#include "keyboard.h"
 
 #ifdef HAVE_SETRLIMIT
 #include <sys/time.h>
@@ -166,6 +167,7 @@
 int initial_argc;
 
 static void sort_args ();
+void syms_of_emacs ();
 
 /* Signal code for the fatal signal that was received */
 int fatal_error_code;
@@ -272,7 +274,7 @@
 
 /* Code for dealing with Lisp access to the Unix command line */
 
-static
+static void
 init_cmdargs (argc, argv, skip_args)
      int argc;
      char **argv;
@@ -449,11 +451,11 @@
    (We don't have any real constructors or destructors.)  */
 #ifdef __GNUC__
 #ifndef GCC_CTORS_IN_LIBC
-__do_global_ctors ()
+void __do_global_ctors ()
 {}
-__do_global_ctors_aux ()
+void __do_global_ctors_aux ()
 {}
-__do_global_dtors ()
+void __do_global_dtors ()
 {}
 /* Linux has a bug in its library; avoid an error.  */
 #ifndef LINUX
@@ -461,7 +463,7 @@
 #endif
 char * __DTOR_LIST__[2] = { (char *) (-1), 0 };
 #endif /* GCC_CTORS_IN_LIBC */
-__main ()
+void __main ()
 {}
 #endif /* __GNUC__ */
 #endif /* ORDINARY_LINK */
@@ -536,6 +538,7 @@
 }
 
 /* ARGSUSED */
+int
 main (argc, argv, envp)
      int argc;
      char **argv;
@@ -544,7 +547,7 @@
   char stack_bottom_variable;
   int skip_args = 0;
   extern int errno;
-  extern sys_nerr;
+  extern int sys_nerr;
 #ifdef HAVE_SETRLIMIT
   struct rlimit rlim;
 #endif
@@ -556,6 +559,7 @@
 #ifdef DOUG_LEA_MALLOC
   if (initialized)
     {
+      extern void r_alloc_reinit ();
       malloc_set_state (malloc_state_ptr);
       free (malloc_state_ptr);
       r_alloc_reinit ();
@@ -1739,6 +1743,7 @@
   return Fnreverse (lpath);
 }
 
+void
 syms_of_emacs ()
 {
   Qfile_name_handler_alist = intern ("file-name-handler-alist");
--- a/src/eval.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/eval.c	Tue Apr 14 12:25:56 1998 +0000
@@ -20,6 +20,11 @@
 
 
 #include <config.h>
+
+#ifdef STDC_HEADERS
+#include <stdlib.h>
+#endif
+
 #include "lisp.h"
 #include "blockinput.h"
 
@@ -162,6 +167,7 @@
 Lisp_Object funcall_lambda ();
 extern Lisp_Object ml_apply (); /* Apply a mocklisp function to unevaluated argument list */
 
+void
 init_eval_once ()
 {
   specpdl_size = 50;
@@ -173,6 +179,7 @@
   Vrun_hooks = Qnil;
 }
 
+void
 init_eval ()
 {
   specpdl_ptr = specpdl;
@@ -199,6 +206,7 @@
   return apply1 (Vdebugger, arg);
 }
 
+void
 do_debug_on_call (code)
      Lisp_Object code;
 {
@@ -2893,6 +2901,7 @@
     }
 }
 
+void
 syms_of_eval ()
 {
   DEFVAR_INT ("max-specpdl-size", &max_specpdl_size,
--- a/src/fileio.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/fileio.c	Tue Apr 14 12:25:56 1998 +0000
@@ -599,6 +599,7 @@
  * Value is nonzero if the string output is different from the input.
  */
 
+int
 directory_file_name (src, dst)
      char *src, *dst;
 {
@@ -4522,6 +4523,7 @@
 	}
       *annot = Fcdr (*annot);
     }
+  return 0;
 }
 
 #ifndef WRITE_BUF_SIZE
@@ -5172,6 +5174,7 @@
   return val;
 }
 
+void
 syms_of_fileio ()
 {
   Qexpand_file_name = intern ("expand-file-name");
--- a/src/filelock.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/filelock.c	Tue Apr 14 12:25:56 1998 +0000
@@ -20,6 +20,7 @@
 
 #include <sys/types.h>
 #include <sys/stat.h>
+#include <signal.h>
 #include <config.h>
 
 #ifdef VMS
@@ -34,6 +35,10 @@
 #include <string.h>
 #endif /* USG */
 
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+
 #include "lisp.h"
 #include "buffer.h"
 
@@ -515,6 +520,7 @@
 
 /* Initialization functions.  */
 
+void
 syms_of_filelock ()
 {
   defsubr (&Sunlock_buffer);
--- a/src/floatfns.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/floatfns.c	Tue Apr 14 12:25:56 1998 +0000
@@ -1010,6 +1010,7 @@
 }
 #endif /* HAVE_MATHERR */
 
+void
 init_floatfns ()
 {
 #ifdef FLOAT_CATCH_SIGILL
@@ -1025,6 +1026,7 @@
 
 #endif /* not LISP_FLOAT_TYPE */
 
+void
 syms_of_floatfns ()
 {
 #ifdef LISP_FLOAT_TYPE
--- a/src/fns.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/fns.c	Tue Apr 14 12:25:56 1998 +0000
@@ -21,6 +21,10 @@
 
 #include <config.h>
 
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+
 /* Note on some machines this defines `vector' as a typedef,
    so make sure we don't use that name in this file.  */
 #undef vector
@@ -35,6 +39,9 @@
 #include "intervals.h"
 #include "frame.h"
 #include "window.h"
+#ifdef HAVE_MENUS
+#include "xterm.h"
+#endif
 
 #ifndef NULL
 #define NULL (void *)0
@@ -44,8 +51,6 @@
    asked by mouse commands.  */
 int use_dialog_box;
 
-extern Lisp_Object Flookup_key ();
-
 extern int minibuffer_auto_raise;
 extern Lisp_Object minibuf_window;
 
@@ -2545,6 +2550,7 @@
   return result;
 }
 
+void
 syms_of_fns ()
 {
   Qstring_lessp = intern ("string-lessp");
--- a/src/fontset.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/fontset.c	Tue Apr 14 12:25:56 1998 +0000
@@ -492,8 +492,6 @@
   return Qnil;
 }
 
-Lisp_Object Fframe_char_width ();
-
 /* Return a list of names of available fontsets matching PATTERN on
    frame F.  If SIZE is not 0, it is the size (maximum bound width) of
    fontsets to be listed. */
@@ -600,7 +598,6 @@
   return Qnil;
 }
 
-extern Lisp_Object Fframe_parameters ();
 extern Lisp_Object Qfont;
 Lisp_Object Qfontset;
 
@@ -802,6 +799,7 @@
   return info;
 }
 
+void
 syms_of_fontset ()
 {
   int i;
--- a/src/frame.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/frame.c	Tue Apr 14 12:25:56 1998 +0000
@@ -28,9 +28,11 @@
 #include "charset.h"
 #ifdef HAVE_WINDOW_SYSTEM
 #include "fontset.h"
+#include "xterm.h"
 #endif
 #include "frame.h"
 #include "termhooks.h"
+#include "dispextern.h"
 #include "window.h"
 #ifdef MSDOS
 #include "msdos.h"
@@ -2224,6 +2226,7 @@
 }
 
 
+void
 syms_of_frame ()
 {
   syms_of_frame_1 ();
@@ -2296,6 +2299,7 @@
   defsubr (&Sset_frame_position);
 }
 
+void
 keys_of_frame ()
 {
   initial_define_lispy_key (global_map, "switch-frame", "handle-switch-frame");
--- a/src/indent.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/indent.c	Tue Apr 14 12:25:56 1998 +0000
@@ -679,6 +679,8 @@
 }
 
 
+static int position_indentation P_ ((int));
+
 DEFUN ("current-indentation", Fcurrent_indentation, Scurrent_indentation,
   0, 0, 0,
   "Return the indentation of the current line.\n\
@@ -1789,6 +1791,7 @@
 
 /* file's initialization.  */
 
+void
 syms_of_indent ()
 {
   DEFVAR_BOOL ("indent-tabs-mode", &indent_tabs_mode,
--- a/src/insdel.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/insdel.c	Tue Apr 14 12:25:56 1998 +0000
@@ -26,6 +26,7 @@
 #include "charset.h"
 #include "window.h"
 #include "blockinput.h"
+#include "region-cache.h"
 
 #ifndef NULL
 #define NULL 0
@@ -777,7 +778,7 @@
 void
 insert (string, nbytes)
      register unsigned char *string;
-     register nbytes;
+     register int nbytes;
 {
   if (nbytes > 0)
     {
@@ -792,7 +793,7 @@
 void
 insert_and_inherit (string, nbytes)
      register unsigned char *string;
-     register nbytes;
+     register int nbytes;
 {
   if (nbytes > 0)
     {
@@ -2441,6 +2442,7 @@
   return unbind_to (count, val);
 }
 
+void
 syms_of_insdel ()
 {
   staticpro (&combine_after_change_list);
--- a/src/intervals.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/intervals.c	Tue Apr 14 12:25:56 1998 +0000
@@ -145,7 +145,7 @@
      INTERVAL i0, i1;
 {
   register Lisp_Object i0_cdr, i0_sym, i1_val;
-  register i1_len;
+  register int i1_len;
 
   if (DEFAULT_INTERVAL_P (i0) && DEFAULT_INTERVAL_P (i1))
     return 1;
@@ -640,7 +640,7 @@
      register INTERVAL interval;
 {
   register INTERVAL i;
-  register position_of_previous;
+  register int position_of_previous;
 
   if (NULL_INTERVAL_P (interval))
     return NULL_INTERVAL;
--- a/src/keyboard.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/keyboard.c	Tue Apr 14 12:25:56 1998 +0000
@@ -492,8 +492,6 @@
 
 static void record_menu_key ();
 
-void swallow_events ();
-
 Lisp_Object Qpolling_period;
 
 /* List of absolute timers.  Appears in order of next scheduled event.  */
@@ -557,6 +555,8 @@
 static Lisp_Object modify_event_symbol ();
 static Lisp_Object make_lispy_switch_frame ();
 static int parse_solitary_modifier ();
+static void save_getcjmp ();
+static void restore_getcjmp ();
 
 /* > 0 if we are to echo keystrokes.  */
 static int echo_keystrokes;
@@ -572,6 +572,7 @@
    so that it serves as a prompt for the next character.
    Also start echoing.  */
 
+void
 echo_prompt (str)
      char *str;
 {
@@ -592,6 +593,7 @@
    C can be a character, which is printed prettily ("M-C-x" and all that
    jazz), or a symbol, whose name is printed.  */
 
+void
 echo_char (c)
      Lisp_Object c;
 {
@@ -641,6 +643,7 @@
 /* Temporarily add a dash to the end of the echo string if it's not
    empty, so that it serves as a mini-prompt for the very next character.  */
 
+void
 echo_dash ()
 {
   if (!current_kboard->immediate_echo
@@ -696,6 +699,7 @@
 
 /* Turn off echoing, for the start of a new command.  */
 
+void
 cancel_echoing ()
 {
   current_kboard->immediate_echo = 0;
@@ -792,6 +796,7 @@
 
 /* Make an auto save happen as soon as possible at command level.  */
 
+void
 force_auto_save_soon ()
 {
   last_auto_save = - auto_save_interval - 1;
@@ -2409,12 +2414,14 @@
    in case get_char is called recursively.
    See read_process_output.  */
 
+static void
 save_getcjmp (temp)
      jmp_buf temp;
 {
   bcopy (getcjmp, temp, sizeof getcjmp);
 }
 
+static void
 restore_getcjmp (temp)
      jmp_buf temp;
 {
@@ -7670,6 +7677,7 @@
 
 /* Return nonzero if input events are pending.  */
 
+int
 detect_input_pending ()
 {
   if (!input_pending)
@@ -7680,6 +7688,7 @@
 
 /* Return nonzero if input events are pending, and run any pending timers.  */
 
+int
 detect_input_pending_run_timers (do_display)
      int do_display;
 {
@@ -7710,6 +7719,7 @@
    The problem is, kbd_buffer_get_event needs to be fixed to know what
    to do in that case.  It isn't trivial.  */
 
+int
 requeued_events_pending_p ()
 {
   return (!NILP (Vunread_command_events) || unread_command_char != -1);
@@ -7953,6 +7963,7 @@
 #endif /* BSD_SYSTEM and not BSD4_1 */
 }
 
+void
 set_waiting_for_input (time_to_clear)
      EMACS_TIME *time_to_clear;
 {
@@ -8311,6 +8322,7 @@
 }
 #endif
 
+void
 init_keyboard ()
 {
   /* This is correct before outermost invocation of the editor loop */
@@ -8405,6 +8417,7 @@
   &Qmake_frame_visible,	"make-frame-visible",	&Qmake_frame_visible,
 };
 
+void
 syms_of_keyboard ()
 {
   staticpro (&item_properties);
@@ -8878,6 +8891,7 @@
   Vtimer_idle_list = Qnil;
 }
 
+void
 keys_of_keyboard ()
 {
   initial_define_key (global_map, Ctl ('Z'), "suspend-emacs");
--- a/src/keymap.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/keymap.c	Tue Apr 14 12:25:56 1998 +0000
@@ -21,6 +21,9 @@
 
 #include <config.h>
 #include <stdio.h>
+#ifdef STDC_HEADERS
+#include <stdlib.h>
+#endif
 #undef NULL
 #include "lisp.h"
 #include "commands.h"
@@ -102,7 +105,6 @@
 static Lisp_Object describe_buffer_bindings ();
 static void describe_command (), describe_translation ();
 static void describe_map ();
-Lisp_Object Fcopy_keymap ();
 
 /* Keymap object support - constructors and predicates.			*/
 
@@ -3168,6 +3170,7 @@
   return apropos_accumulate;
 }
 
+void
 syms_of_keymap ()
 {
   Lisp_Object tem;
@@ -3305,6 +3308,7 @@
   defsubr (&Sapropos_internal);
 }
 
+void
 keys_of_keymap ()
 {
   Lisp_Object tem;
--- a/src/marker.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/marker.c	Tue Apr 14 12:25:56 1998 +0000
@@ -36,6 +36,7 @@
 
 static int byte_debug_flag;
 
+void
 clear_charpos_cache (b)
      struct buffer *b;
 {
--- a/src/mocklisp.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/mocklisp.c	Tue Apr 14 12:25:56 1998 +0000
@@ -227,6 +227,7 @@
 }
 
 
+void
 syms_of_mocklisp ()
 {
   Qmocklisp = intern ("mocklisp");
--- a/src/prefix-args.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/prefix-args.c	Tue Apr 14 12:25:56 1998 +0000
@@ -26,6 +26,7 @@
 
 #include <stdio.h>
 
+int
 main (argc, argv)
      int argc;
      char **argv;
--- a/src/print.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/print.c	Tue Apr 14 12:25:56 1998 +0000
@@ -683,7 +683,7 @@
 Lisp_Object
 internal_with_output_to_temp_buffer (bufname, function, args)
      char *bufname;
-     Lisp_Object (*function) ();
+     Lisp_Object (*function) P_ ((Lisp_Object));
      Lisp_Object args;
 {
   int count = specpdl_ptr - specpdl;
--- a/src/process.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/process.c	Tue Apr 14 12:25:56 1998 +0000
@@ -106,6 +106,8 @@
 #include "commands.h"
 #include "frame.h"
 #include "blockinput.h"
+#include "keyboard.h"
+#include "dispextern.h"
 
 #define max(a, b) ((a) > (b) ? (a) : (b))
 
@@ -279,6 +281,7 @@
 
 Lisp_Object status_convert ();
 
+void
 update_status (p)
      struct Lisp_Process *p;
 {
@@ -391,7 +394,7 @@
 allocate_pty ()
 {
   struct stat stb;
-  register c, i;
+  register int c, i;
   int fd;
 
   /* Some systems name their pseudoterminals so that there are gaps in
@@ -512,6 +515,7 @@
   return val;
 }
 
+void
 remove_process (proc)
      register Lisp_Object proc;
 {
@@ -2173,7 +2177,7 @@
 static int waiting_for_user_input_p;
 
 /* This is here so breakpoints can be put on it.  */
-static
+static void
 wait_reading_process_input_1 ()
 {
 }
@@ -2210,6 +2214,7 @@
      before the timeout elapsed.
    Otherwise, return true iff we received input from any process.  */
 
+int
 wait_reading_process_input (time_limit, microsecs, read_kbd, do_display)
      int time_limit, microsecs;
      Lisp_Object read_kbd;
@@ -2708,6 +2713,7 @@
    The characters read are decoded according to PROC's coding-system
    for decoding.  */
 
+int
 read_process_output (proc, channel)
      Lisp_Object proc;
      register int channel;
@@ -3062,6 +3068,7 @@
    being encoded.  Should we store them in a buffer to prepend them to
    the data send later?  */
 
+void
 send_process (proc, buf, len, object)
      volatile Lisp_Object proc;
      unsigned char *buf;
@@ -4289,6 +4296,7 @@
   return 0;
 }
 
+void
 init_process ()
 {
   register int i;
@@ -4317,6 +4325,7 @@
   bzero (proc_encode_coding_system, sizeof proc_encode_coding_system);
 }
 
+void
 syms_of_process ()
 {
   Qprocessp = intern ("processp");
--- a/src/scroll.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/scroll.c	Tue Apr 14 12:25:56 1998 +0000
@@ -264,7 +264,7 @@
   bcopy (current_frame->glyphs, temp_frame->glyphs,
 	 current_frame->height * sizeof (GLYPH *));
   bcopy (current_frame->charstarts, temp_frame->charstarts,
-	 current_frame->height * sizeof (GLYPH *));
+	 current_frame->height * sizeof (int *));
   bcopy (current_frame->used, temp_frame->used,
 	 current_frame->height * sizeof (int));
   bcopy (current_frame->highlight, temp_frame->highlight,
@@ -889,6 +889,7 @@
    These are the same arguments that might be given to
    scroll_frame_lines to perform this scrolling.  */
 
+int
 scroll_cost (frame, from, to, amount)
      FRAME_PTR frame;
      int from, to, amount;
@@ -1008,6 +1009,7 @@
    Deletion is essentially the same as insertion.
  */
 
+void
 do_line_insertion_deletion_costs (frame,
 				  ins_line_string, multi_ins_string,
 				  del_line_string, multi_del_string,
--- a/src/search.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/search.c	Tue Apr 14 12:25:56 1998 +0000
@@ -20,6 +20,9 @@
 
 
 #include <config.h>
+#ifdef STDC_HEADERS
+#include <stdlib.h>
+#endif
 #include "lisp.h"
 #include "syntax.h"
 #include "category.h"
@@ -515,6 +518,7 @@
    If ALLOW_QUIT is non-zero, set immediate_quit.  That's good to do
    except when inside redisplay.  */
 
+int
 scan_buffer (target, start, end, count, shortage, allow_quit)
      register int target;
      int start, end;
@@ -2715,6 +2719,7 @@
 				STRING_MULTIBYTE (string));
 }
   
+void
 syms_of_search ()
 {
   register int i;
--- a/src/syntax.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/syntax.c	Tue Apr 14 12:25:56 1998 +0000
@@ -1065,6 +1065,7 @@
    If that many words cannot be found before the end of the buffer, return 0.
    COUNT negative means scan backward and stop at word beginning.  */
 
+int
 scan_words (from, count)
      register int from, count;
 {
@@ -2605,6 +2606,7 @@
 				     Qnil)))))))));
 }
 
+void
 init_syntax_once ()
 {
   register int i, c;
@@ -2676,6 +2678,7 @@
     }
 }
 
+void
 syms_of_syntax ()
 {
   Qsyntax_table_p = intern ("syntax-table-p");
--- a/src/sysdep.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/sysdep.c	Tue Apr 14 12:25:56 1998 +0000
@@ -298,6 +298,7 @@
 /* Arrange for character C to be read as the next input from
    the terminal.  */
 
+void
 stuff_char (c)
      char c;
 {
@@ -377,6 +378,7 @@
 }
 
 /*ARGSUSED*/
+void
 set_exclusive_use (fd)
      int fd;
 {
@@ -1028,6 +1030,7 @@
    When we are in the foreground, but not started in our own process
    group, redirect the TTY to point to our own process group.  We need
    to be in our own process group to receive SIGIO properly.  */
+void
 narrow_foreground_group ()
 {
   int me = getpid ();
@@ -1039,6 +1042,7 @@
 }
 
 /* Set the tty to our original foreground group.  */
+void
 widen_foreground_group ()
 {
   if (inherited_pgroup != getpid ())
@@ -1595,6 +1599,7 @@
 /* Return nonzero if safe to use tabs in output.
    At the time this is called, init_sys_modes has not been done yet.  */
    
+int
 tabs_safe_p ()
 {
   struct emacs_tty tty;
@@ -1848,6 +1853,7 @@
    This is called each time Emacs is resumed, also, but does nothing
    because input_chain is no longer zero.  */
 
+void
 init_vms_input ()
 {
   int status;
@@ -1862,6 +1868,7 @@
 
 /* Deassigning the input channel is done before exiting.  */
 
+void
 stop_vms_input ()
 {
   return SYS$DASSGN (input_fd);
@@ -1872,6 +1879,7 @@
 /* Request reading one character into the keyboard buffer.
    This is done as soon as the buffer becomes empty.  */
 
+void
 queue_kbd_input ()
 {
   int status;
@@ -1889,6 +1897,7 @@
 /* Ast routine that is called when keyboard input comes in
    in accord with the SYS$QIO above.  */
 
+void
 kbd_input_ast ()
 {
   register int c = -1;
@@ -1936,6 +1945,7 @@
 
 /* Wait until there is something in kbd_buffer.  */
 
+void
 wait_for_kbd_input ()
 {
   extern int have_process_input, process_exited;
@@ -1982,6 +1992,7 @@
    and therefore there is no I/O request queued when we return.
    SYS$SETAST is used to avoid a timing error.  */
 
+void
 end_kbd_input ()
 {
 #ifdef ASTDEBUG
@@ -2008,6 +2019,7 @@
 
 /* Wait for either input available or time interval expiry.  */
 
+void
 input_wait_timeout (timeval)
      int timeval;		/* Time to wait, in seconds */
 {
@@ -2564,6 +2576,7 @@
 #define BUFFER_SIZE_FACTOR 1
 #endif
 
+void
 read_input_waiting ()
 {
   struct input_event e;
@@ -2657,6 +2670,7 @@
   ioctl (fd, TIOCLSET, &lmode);
 }
 
+void
 reset_sigio ()
 {
   if (noninteractive)
@@ -2686,6 +2700,7 @@
 
 int sigheld; /* Mask of held signals */
 
+void
 sigholdx (signum)
      int signum;
 {
@@ -2693,12 +2708,14 @@
   sighold (signum);
 }
 
+void
 sigisheld (signum)
      int signum;
 {
   sigheld |= sigbit (signum);
 }
 
+void
 sigunhold (signum)
      int signum;
 {
@@ -2706,6 +2723,7 @@
   sigrelse (signum);
 }
 
+void
 sigfree ()    /* Free all held signals */
 {
   int i;
@@ -2715,6 +2733,7 @@
   sigheld = 0;
 }
 
+int
 sigbit (i)
 {
   return 1 << (i - 1);
@@ -2729,6 +2748,7 @@
 
 sigset_t empty_mask, full_mask;
 
+void
 init_signals ()
 {
   sigemptyset (&empty_mask);
@@ -3023,6 +3043,7 @@
 
 #ifdef INTERRUPTIBLE_CLOSE
 
+int
 sys_close (fd)
      int fd;
 {
@@ -3326,6 +3347,7 @@
 #ifdef HAVE_TIMEVAL
  
 /* ARGSUSED */
+int
 gettimeofday (tp, tzp)
      struct timeval *tp;
      struct timezone *tzp;
@@ -3336,6 +3358,7 @@
   tp->tv_usec = 0;
   if (tzp != 0)
     tzp->tz_minuteswest = -1;
+  return 0;
 }
  
 #endif
@@ -3347,6 +3370,7 @@
  *	This function will go away as soon as all the stubs fixed. (fnf)
  */
 
+void
 croak (badfunc)
      char *badfunc;
 {
@@ -3871,6 +3895,7 @@
 
 /* Called from init_sys_modes, so it happens not very often
    but at least each time Emacs is loaded.  */
+void
 sys_access_reinit ()
 {
   uic = 0;
@@ -4123,6 +4148,7 @@
  return pathname;
 }
 
+int
 getppid ()
 {
   long item_code = JPI$_OWNER;
@@ -4318,6 +4344,7 @@
 #endif
 #endif
 
+int
 sys_creat (va_alist)
      va_dcl
 {
@@ -4434,6 +4461,7 @@
 #endif /* creat */
 
 /* fwrite to stdout is S L O W.  Speed it up by using fputc...*/
+int
 sys_fwrite (ptr, size, num, fp)
      register char * ptr;
      FILE * fp;
@@ -4442,6 +4470,7 @@
 
   while (tot--)
     fputc (*ptr++, fp);
+  return num;
 }
 
 /*
@@ -4729,6 +4758,7 @@
 /* return total address space available to the current process.  This is
    the sum of the current p0 size, p1 size and free page table entries
    available. */
+int
 vlimit ()
 {
   int item_code;
@@ -4764,6 +4794,7 @@
   return free_pages + frep0va + (0x7fffffff - frep1va);
 }
 
+int
 define_logical_name (varname, string)
      char *varname;
      char *string;
@@ -4778,6 +4809,7 @@
   return LIB$SET_LOGICAL (&envdsc, &strdsc, &lnmdsc, 0, 0);
 }
 
+int
 delete_logical_name (varname)
      char *varname;
 {
@@ -4789,15 +4821,23 @@
   return LIB$DELETE_LOGICAL (&envdsc, &lnmdsc);
 }
 
+int
 ulimit ()
-{}
-
+{
+  return 0;
+}
+
+int
 setpgrp ()
-{}
-
+{
+  return 0;
+}
+
+int
 execvp ()
 {
   error ("execvp system call not implemented");
+  return -1;
 }
 
 int
@@ -4920,6 +4960,7 @@
   return 0;
 }
 
+int
 link (file, new)
      char * file, * new;
 {
@@ -4987,6 +5028,7 @@
   return 0;
 }
 
+void
 croak (badfunc)
      char *badfunc;
 {
@@ -5002,6 +5044,7 @@
   return rand () - (1 << 30);
 }
 
+void
 srandom (seed)
 {
   srand (seed);
@@ -5011,6 +5054,7 @@
 #ifdef AIXHFT
 
 /* Called from init_sys_modes.  */
+void
 hft_init ()
 {
   int junk;
@@ -5064,6 +5108,7 @@
 
 /* Reset the rubout key to backspace. */
 
+void
 hft_reset ()
 {
   struct hfbuf buf;
@@ -5183,7 +5228,7 @@
     *b2++ = *b1++;
 #endif /* not VMS */
 }
-#endif /* (defined (BSTRING) && !defined (bcopy)) || defined (NEED_BCOPY) */
+#endif /* (!defined (BSTRING) && !defined (bcopy)) || defined (NEED_BCOPY) */
 
 #ifndef BSTRING
 #ifndef bcmp
--- a/src/term.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/term.c	Tue Apr 14 12:25:56 1998 +0000
@@ -33,8 +33,10 @@
 #include "disptab.h"
 #include "termhooks.h"
 #include "keyboard.h"
-
-extern Lisp_Object Fmake_sparse_keymap ();
+#include "dispextern.h"
+#ifdef HAVE_X_WINDOWS
+#include "xterm.h"
+#endif
 
 #define max(a, b) ((a) > (b) ? (a) : (b))
 #define min(a, b) ((a) < (b) ? (a) : (b))
@@ -74,33 +76,33 @@
 /* Hook functions that you can set to snap out the functions in this file.
    These are all extern'd in termhooks.h  */
 
-int (*cursor_to_hook) ();
-int (*raw_cursor_to_hook) ();
+void (*cursor_to_hook) P_ ((int, int));
+void (*raw_cursor_to_hook) P_ ((int, int));
 
-int (*clear_to_end_hook) ();
-int (*clear_frame_hook) ();
-int (*clear_end_of_line_hook) ();
+void (*clear_to_end_hook) P_ ((void));
+void (*clear_frame_hook) P_ ((void));
+void (*clear_end_of_line_hook) P_ ((int));
 
-int (*ins_del_lines_hook) ();
+void (*ins_del_lines_hook) P_ ((int, int));
 
-int (*change_line_highlight_hook) ();
-int (*reassert_line_highlight_hook) ();
+void (*change_line_highlight_hook) P_ ((int, int, int));
+void (*reassert_line_highlight_hook) P_ ((int, int));
 
-int (*insert_glyphs_hook) ();
-int (*write_glyphs_hook) ();
-int (*delete_glyphs_hook) ();
+void (*insert_glyphs_hook) P_ ((GLYPH *, int));
+void (*write_glyphs_hook) P_ ((GLYPH *, int));
+void (*delete_glyphs_hook) P_ ((int));
 
-int (*ring_bell_hook) ();
+void (*ring_bell_hook) P_ ((void));
 
-int (*reset_terminal_modes_hook) ();
-int (*set_terminal_modes_hook) ();
-int (*update_begin_hook) ();
-int (*update_end_hook) ();
-int (*set_terminal_window_hook) ();
+void (*reset_terminal_modes_hook) P_ ((void));
+void (*set_terminal_modes_hook) P_ ((void));
+void (*update_begin_hook) P_ ((struct frame *));
+void (*update_end_hook) P_ ((struct frame *));
+void (*set_terminal_window_hook) P_ ((int));
 
-int (*read_socket_hook) ();
+int (*read_socket_hook) P_ ((int, struct input_event *, int, int));
 
-int (*frame_up_to_date_hook) ();
+void (*frame_up_to_date_hook) P_ ((struct frame *));
 
 /* Return the current position of the mouse.
 
@@ -120,19 +122,19 @@
 
    This should clear mouse_moved until the next motion
    event arrives.  */
-void (*mouse_position_hook) ( /* FRAME_PTR *f, int insist,
+void (*mouse_position_hook) P_ ((FRAME_PTR *f, int insist,
 				 Lisp_Object *bar_window,
 				 enum scroll_bar_part *part,
 				 Lisp_Object *x,
 				 Lisp_Object *y,
-				 unsigned long *time */ );
+				 unsigned long *time));
 
 /* When reading from a minibuffer in a different frame, Emacs wants
    to shift the highlight from the selected frame to the minibuffer's
    frame; under X, this means it lies about where the focus is.
    This hook tells the window system code to re-decide where to put
    the highlight.  */
-void (*frame_rehighlight_hook) ( /* FRAME_PTR f */ );
+void (*frame_rehighlight_hook) P_ ((FRAME_PTR f));
 
 /* If we're displaying frames using a window system that can stack
    frames on top of each other, this hook allows you to bring a frame
@@ -144,7 +146,7 @@
    If RAISE is non-zero, F is brought to the front, before all other
    windows.  If RAISE is zero, F is sent to the back, behind all other
    windows.  */
-void (*frame_raise_lower_hook) ( /* FRAME_PTR f, int raise */ );
+void (*frame_raise_lower_hook) P_ ((FRAME_PTR f, int raise));
 
 /* Set the vertical scroll bar for WINDOW to have its upper left corner
    at (TOP, LEFT), and be LENGTH rows high.  Set its handle to
@@ -152,8 +154,8 @@
    of WHOLE characters, starting at POSITION.  If WINDOW doesn't yet
    have a scroll bar, create one for it.  */
 void (*set_vertical_scroll_bar_hook)
-     ( /* struct window *window,
-	  int portion, int whole, int position */ );
+     P_ ((struct window *window,
+	  int portion, int whole, int position));
 
 
 /* The following three hooks are used when we're doing a thorough
@@ -176,11 +178,11 @@
    If non-zero, this hook should be safe to apply to any frame,
    whether or not it can support scroll bars, and whether or not it is
    currently displaying them.  */
-void (*condemn_scroll_bars_hook)( /* FRAME_PTR *frame */ );
+void (*condemn_scroll_bars_hook) P_ ((FRAME_PTR frame));
 
 /* Unmark WINDOW's scroll bar for deletion in this judgement cycle.
    Note that it's okay to redeem a scroll bar that is not condemned.  */
-void (*redeem_scroll_bar_hook)( /* struct window *window */ );
+void (*redeem_scroll_bar_hook) P_ ((struct window *window));
 
 /* Remove all scroll bars on FRAME that haven't been saved since the
    last call to `*condemn_scroll_bars_hook'.  
@@ -193,7 +195,7 @@
    If non-zero, this hook should be safe to apply to any frame,
    whether or not it can support scroll bars, and whether or not it is
    currently displaying them.  */
-void (*judge_scroll_bars_hook)( /* FRAME_PTR *FRAME */ );
+void (*judge_scroll_bars_hook) P_ ((FRAME_PTR FRAME));
 
 
 /* Strings, numbers and flags taken from the termcap entry.  */
@@ -319,6 +321,7 @@
 #define FRAME_TERMCAP_P(_f_) 0
 #endif /* WINDOWSNT */
 
+void
 ring_bell ()
 {
   if (! NILP (Vring_bell_function))
@@ -349,6 +352,7 @@
   OUTPUT (TS_visible_bell && visible_bell ? TS_visible_bell : TS_bell);
 }
 
+void
 set_terminal_modes ()
 {
   if (! FRAME_TERMCAP_P (selected_frame))
@@ -362,6 +366,7 @@
   losecursor ();
 }
 
+void
 reset_terminal_modes ()
 {
   if (! FRAME_TERMCAP_P (selected_frame))
@@ -383,6 +388,7 @@
   cmputc ('\r');
 }
 
+void
 update_begin (f)
      FRAME_PTR f;
 {
@@ -391,6 +397,7 @@
     (*update_begin_hook) (f);
 }
 
+void
 update_end (f)
      FRAME_PTR f;
 {
@@ -406,6 +413,7 @@
   updating_frame = 0;
 }
 
+void
 set_terminal_window (size)
      int size;
 {
@@ -420,6 +428,7 @@
   set_scroll_region (0, specified_window);
 }
 
+void
 set_scroll_region (start, stop)
      int start, stop;
 {
@@ -444,6 +453,7 @@
   losecursor ();
 }
 
+void
 turn_on_insert ()
 {
   if (!insert_mode)
@@ -451,6 +461,7 @@
   insert_mode = 1;
 }
 
+void
 turn_off_insert ()
 {
   if (insert_mode)
@@ -465,6 +476,7 @@
    These functions are called on all terminals, but do nothing
    on terminals whose standout mode does not work that way.  */
 
+void
 turn_off_highlight ()
 {
   if (TN_standout_width < 0)
@@ -475,6 +487,7 @@
     }
 }
 
+void
 turn_on_highlight ()
 {
   if (TN_standout_width < 0)
@@ -489,6 +502,7 @@
    empty space inside windows.  What this is,
    depends on the user option inverse-video.  */
 
+void
 background_highlight ()
 {
   if (TN_standout_width >= 0)
@@ -501,7 +515,7 @@
 
 /* Set standout mode to the mode specified for the text to be output.  */
 
-static
+static void
 highlight_if_desired ()
 {
   if (TN_standout_width >= 0)
@@ -523,6 +537,7 @@
 /* Write a standout marker or end-standout marker at the front of the line
    at vertical position vpos.  */
 
+void
 write_standout_marker (flag, vpos)
      int flag, vpos;
 {
@@ -540,6 +555,7 @@
    Call this when about to modify line at position VPOS
    and not change whether it is highlighted.  */
 
+void
 reassert_line_highlight (highlight, vpos)
      int highlight;
      int vpos;
@@ -561,6 +577,7 @@
 /* Call this when about to modify line at position VPOS
    and change whether it is highlighted.  */
 
+void
 change_line_highlight (new_highlight, vpos, first_unused_hpos)
      int new_highlight, vpos, first_unused_hpos;
 {
@@ -597,6 +614,7 @@
 
 /* Move to absolute position, specified origin 0 */
 
+void
 cursor_to (row, col)
      int row, col;
 {
@@ -626,6 +644,7 @@
 
 /* Similar but don't take any account of the wasted characters.  */
 
+void
 raw_cursor_to (row, col)
      int row, col;
 {
@@ -646,6 +665,7 @@
 /* Erase operations */
 
 /* clear from cursor to end of frame */
+void
 clear_to_end ()
 {
   register int i;
@@ -673,6 +693,7 @@
 
 /* Clear entire frame */
 
+void
 clear_frame ()
 {
   if (clear_frame_hook
@@ -702,6 +723,7 @@
 
    Note that the cursor may be moved.  */
 
+void
 clear_end_of_line (first_unused_hpos)
      int first_unused_hpos;
 {
@@ -719,6 +741,7 @@
 
    Note that the cursor may be moved, on terminals lacking a `ce' string.  */
 
+void
 clear_end_of_line_raw (first_unused_hpos)
      int first_unused_hpos;
 {
@@ -849,6 +872,7 @@
 }
 
 
+void
 write_glyphs (string, len)
      register GLYPH *string;
      register int len;
@@ -922,6 +946,7 @@
 
 /* If start is zero, insert blanks instead of a string at start */
  
+void
 insert_glyphs (start, len)
      register GLYPH *start;
      register int len;
@@ -996,6 +1021,7 @@
   cmcheckmagic ();
 }
 
+void
 delete_glyphs (n)
      register int n;
 {
@@ -1033,6 +1059,7 @@
 
 /* Insert N lines at vpos VPOS.  If N is negative, delete -N lines.  */
 
+void
 ins_del_lines (vpos, n)
      int vpos, n;
 {
@@ -1093,7 +1120,7 @@
 
   if (TN_standout_width >= 0)
     {
-      register lower_limit
+      register int lower_limit
 	= (scroll_region_ok
 	   ? specified_window
 	   : FRAME_HEIGHT (selected_frame));
@@ -1233,8 +1260,7 @@
     *p++ = (ins_startup_cost += ins_cost_per_char);
 }
 
-extern do_line_insertion_deletion_costs ();
-
+void
 calculate_costs (frame)
      FRAME_PTR frame;
 {
@@ -1534,6 +1560,7 @@
 }
 
 
+void
 term_init (terminal_type)
      char *terminal_type;
 {
@@ -1904,6 +1931,7 @@
 }
 
 /* VARARGS 1 */
+void
 fatal (str, arg1, arg2)
      char *str, *arg1, *arg2;
 {
@@ -1914,6 +1942,7 @@
   exit (1);
 }
 
+void
 syms_of_term ()
 {
   DEFVAR_BOOL ("system-uses-terminfo", &system_uses_terminfo,
--- a/src/terminfo.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/terminfo.c	Tue Apr 14 12:25:56 1998 +0000
@@ -39,8 +39,6 @@
 #endif
 #endif
 
-static buffer[512];
-
 /* Interface to curses/terminfo library.
    Turns out that all of the terminfo-level routines look
    like their termcap counterparts except for tparm, which replaces
--- a/src/undo.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/undo.c	Tue Apr 14 12:25:56 1998 +0000
@@ -524,6 +524,7 @@
   return unbind_to (count, list);
 }
 
+void
 syms_of_undo ()
 {
   Qinhibit_read_only = intern ("inhibit-read-only");
--- a/src/widget.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/widget.c	Tue Apr 14 12:25:56 1998 +0000
@@ -36,6 +36,7 @@
 #include "xterm.h"
 
 #include "frame.h"
+#include "window.h"
 
 #include "dispextern.h"
 #include "blockinput.h"
@@ -967,6 +968,7 @@
   SET_FRAME_GARBAGED (f);
 }
 
+void
 widget_store_internal_border (widget)
      Widget widget;
 {
--- a/src/window.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/window.c	Tue Apr 14 12:25:56 1998 +0000
@@ -30,6 +30,10 @@
 #include "disptab.h"
 #include "keyboard.h"
 #include "blockinput.h"
+#include "dispextern.h"
+#ifdef HAVE_WINDOW_SYSTEM
+#include "xterm.h"
+#endif
 
 Lisp_Object Qwindowp, Qwindow_live_p;
 
@@ -723,7 +727,7 @@
 
 /* Record info on buffer window w is displaying
    when it is about to cease to display that buffer.  */
-static
+static void
 unshow_buffer (w)
      register struct window *w;
 {
@@ -767,7 +771,7 @@
 }
 
 /* Put replacement into the window structure in place of old. */
-static
+static void
 replace_window (old, replacement)
      Lisp_Object old, replacement;
 {
@@ -2365,7 +2369,7 @@
     }
 }
 
-static
+static void
 make_dummy_parent (window)
      Lisp_Object window;
 {
@@ -3799,6 +3803,7 @@
   return Qnil;
 }
 
+void
 init_window_once ()
 {
   selected_frame = make_terminal_frame ();
@@ -3810,6 +3815,7 @@
   window_initialized = 1;
 }
 
+void
 syms_of_window ()
 {
   staticpro (&Qwindow_configuration_change_hook);
@@ -4029,6 +4035,7 @@
   defsubr (&Scompare_window_configurations);
 }
 
+void
 keys_of_window ()
 {
   initial_define_key (control_x_map, '1', "delete-other-windows");
--- a/src/xdisp.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/xdisp.c	Tue Apr 14 12:25:56 1998 +0000
@@ -40,6 +40,11 @@
 #include "keyboard.h"
 #include "coding.h"
 #include "process.h"
+#include "region-cache.h"
+
+#ifdef HAVE_WINDOW_SYSTEM
+#include "xterm.h"
+#endif
 
 #if defined (USE_X_TOOLKIT) || defined (HAVE_NTGUI)
 extern void set_frame_menubar ();
@@ -5468,6 +5473,7 @@
 }
 
 /* initialize the window system */
+void
 init_xdisp ()
 {
   Lisp_Object root_window;
--- a/src/xmenu.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/xmenu.c	Tue Apr 14 12:25:56 1998 +0000
@@ -686,7 +686,7 @@
 	  /* Use the mouse's current position.  */
 	  FRAME_PTR new_f = selected_frame;
 	  Lisp_Object bar_window;
-	  int part;
+	  enum scroll_bar_part part;
 	  unsigned long time;
 
 	  if (mouse_position_hook)
@@ -1095,6 +1095,7 @@
    passing it to the toolkit right away, is that we can safely
    execute Lisp code.  */
    
+void
 x_activate_menubar (f)
      FRAME_PTR f;
 {
@@ -2606,6 +2607,7 @@
 
 #endif /* HAVE_MENUS */
 
+void
 syms_of_xmenu ()
 {
   staticpro (&menu_items);
--- a/src/xrdb.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/xrdb.c	Tue Apr 14 12:25:56 1998 +0000
@@ -24,6 +24,10 @@
 #include <config.h>
 #endif
 
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+
 #include <paths.h>
 
 #include <stdio.h>
@@ -84,6 +88,7 @@
 #define malloc xmalloc
 #define realloc xrealloc
 #define free xfree
+extern long *xmalloc (), *xrealloc ();
 #endif
 
 char *x_get_string_resource ();
--- a/src/xselect.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/xselect.c	Tue Apr 14 12:25:56 1998 +0000
@@ -30,6 +30,7 @@
 #include "buffer.h"
 #include "charset.h"
 #include "coding.h"
+#include "process.h"
 
 #define CUT_BUFFER_SUPPORT
 
--- a/src/xterm.c	Tue Apr 14 10:56:46 1998 +0000
+++ b/src/xterm.c	Tue Apr 14 12:25:56 1998 +0000
@@ -86,6 +86,7 @@
 #include "window.h"
 #include "keyboard.h"
 #include "intervals.h"
+#include "process.h"
 
 #ifdef USE_X_TOOLKIT
 #include <X11/Shell.h>
@@ -147,7 +148,7 @@
    is the frame to apply to.  */
 extern struct frame *updating_frame;
 
-extern waiting_for_input;
+extern int waiting_for_input;
 
 /* This is a frame waiting to be autoraised, within XTread_socket.  */
 struct frame *pending_autoraise_frame;
@@ -265,8 +266,8 @@
 static void show_mouse_face ();
 static void do_line_dance ();
 
-static int XTcursor_to ();
-static int XTclear_end_of_line ();
+static void XTcursor_to ();
+static void XTclear_end_of_line ();
 static int x_io_error_quitter ();
 int x_catch_errors ();
 void x_uncatch_errors ();
@@ -323,7 +324,7 @@
    should never be called except during an update, the only exceptions
    being XTcursor_to, XTwrite_glyphs and XTreassert_line_highlight.  */
 
-static
+static void
 XTupdate_begin (f)
      struct frame *f;
 {
@@ -383,7 +384,7 @@
   UNBLOCK_INPUT;
 }
 
-static
+static void
 XTupdate_end (f)
      struct frame *f;
 {
@@ -413,7 +414,7 @@
 
 /* This is called after a redisplay on frame F.  */
 
-static
+static void
 XTframe_up_to_date (f)
      FRAME_PTR f;
 {
@@ -434,6 +435,7 @@
    Call this when about to modify line at position VPOS
    and not change whether it is highlighted.  */
 
+void
 XTreassert_line_highlight (new, vpos)
      int new, vpos;
 {
@@ -443,7 +445,7 @@
 /* Call this when about to modify line at position VPOS
    and change whether it is highlighted.  */
 
-static
+static void
 XTchange_line_highlight (new_highlight, vpos, first_unused_hpos)
      int new_highlight, vpos, first_unused_hpos;
 {
@@ -456,7 +458,7 @@
    When starting Emacs, no X window is mapped.  And nothing must be done
    to Emacs's own window if it is suspended (though that rarely happens).  */
 
-static
+static void
 XTset_terminal_modes ()
 {
 }
@@ -465,7 +467,7 @@
    Exiting will make the X-windows go away, and suspending
    requires no action.  */
 
-static
+static void
 XTreset_terminal_modes ()
 {
 /*  XTclear_frame ();  */
@@ -475,7 +477,7 @@
    This is where display update commands will take effect.
    This does not affect the place where the cursor-box is displayed.  */
 
-static int
+static void
 XTcursor_to (row, col)
      register int row, col;
 {
@@ -1184,7 +1186,7 @@
    `highlight', set up by XTreassert_line_highlight or XTchange_line_highlight,
    controls the pixel values used for foreground and background.  */
 
-static
+static void
 XTwrite_glyphs (start, len)
      register GLYPH *start;
      int len;
@@ -1230,7 +1232,7 @@
    to column FIRST_UNUSED (exclusive).  The idea is that everything
    from FIRST_UNUSED onward is already erased.  */
 
-static
+static void
 XTclear_end_of_line (first_unused)
      register int first_unused;
 {
@@ -1272,7 +1274,7 @@
   UNBLOCK_INPUT;
 }
 
-static
+static void
 XTclear_frame ()
 {
   int mask;
@@ -1508,6 +1510,7 @@
   return x.tv_sec < y.tv_sec;
 }
 
+void
 XTflash (f)
      struct frame *f;
 {
@@ -1635,6 +1638,7 @@
 
 #define XRINGBELL XBell (FRAME_X_DISPLAY (selected_frame), 0)
 
+void
 XTring_bell ()
 {
   if (FRAME_X_DISPLAY (selected_frame) == 0)
@@ -1657,7 +1661,7 @@
    These are not supposed to be used because we are supposed to turn
    off the feature of using them.  */
 
-static
+static void
 XTinsert_glyphs (start, len)
      register char *start;
      register int len;
@@ -1665,7 +1669,7 @@
   abort ();
 }
 
-static
+static void
 XTdelete_glyphs (n)
      register int n;
 {
@@ -1677,7 +1681,7 @@
    This, and those operations, are used only within an update
    that is bounded by calls to XTupdate_begin and XTupdate_end.  */
 
-static
+static void
 XTset_terminal_window (n)
      register int n;
 {
@@ -1708,6 +1712,7 @@
 
 /* Perform an insert-lines or delete-lines operation,
    inserting N lines or deleting -N lines at vertical position VPOS.  */
+void
 XTins_del_lines (vpos, n)
      int vpos, n;
 {
@@ -2693,6 +2698,7 @@
 /* Just discard the mouse face information for frame F, if any.
    This is used when the size of F is changed.  */
 
+void
 cancel_mouse_face (f)
      FRAME_PTR f;
 {
@@ -3560,6 +3566,7 @@
    Clear out the scroll bars, and ask for expose events, so we can
    redraw them.  */
 
+void
 x_scroll_bar_clear (f)
      FRAME_PTR f;
 {
@@ -3959,7 +3966,7 @@
 	      if (! x_window_to_frame (dpyinfo, event.xselection.requestor))
 		goto OTHER;
 #endif /* not USE_X_TOOLKIT */
-	      x_handle_selection_notify (&event);
+	      x_handle_selection_notify (&event.xselection);
 	      break;
 
 	    case SelectionClear:	/* Someone has grabbed ownership. */
@@ -4020,7 +4027,7 @@
 	      if (!x_any_window_to_frame (dpyinfo, event.xproperty.window))
 		goto OTHER;
 #endif /* not USE_X_TOOLKIT */
-	      x_handle_property_notify (&event);
+	      x_handle_property_notify (&event.xproperty);
 	      break;
 
 	    case ReparentNotify:
@@ -4896,6 +4903,7 @@
 /* Display the cursor on frame F, or clear it, according to ON.
    Also set the frame's cursor position to X and Y.  */
 
+void
 x_display_cursor (f, on, x, y)
      struct frame *f;
      int on;
@@ -4921,6 +4929,7 @@
 /* Display the cursor on frame F, or clear it, according to ON.
    Don't change the cursor's position.  */
 
+void
 x_update_cursor (f, on)
      struct frame *f;
      int on;
@@ -4943,6 +4952,7 @@
 /* Refresh bitmap kitchen sink icon for frame F
    when we get an expose event for it. */
 
+void
 refreshicon (f)
      struct frame *f;
 {
@@ -5390,6 +5400,7 @@
 /* Calculate the absolute position in frame F
    from its current recorded position values and gravity.  */
 
+void
 x_calc_absolute_position (f)
      struct frame *f;
 {
@@ -5482,6 +5493,7 @@
    position values).  It is -1 when calling from x_set_frame_parameters,
    which means, do adjust for borders but don't change the gravity.  */
 
+void
 x_set_offset (f, xoff, yoff, change_gravity)
      struct frame *f;
      register int xoff, yoff;
@@ -5533,6 +5545,7 @@
    for this size change and subsequent size changes.
    Otherwise we leave the window gravity unchanged.  */
 
+void
 x_set_window_size (f, change_gravity, cols, rows)
      struct frame *f;
      int change_gravity;
@@ -5659,6 +5672,7 @@
 
 /* focus shifting, raising and lowering.  */
 
+void
 x_focus_on_frame (f)
      struct frame *f;
 {
@@ -5674,6 +5688,7 @@
 #endif /* ! 0 */
 }
 
+void
 x_unfocus_frame (f)
      struct frame *f;
 {
@@ -5687,6 +5702,7 @@
 
 /* Raise frame F.  */
 
+void
 x_raise_frame (f)
      struct frame *f;
 {
@@ -5705,6 +5721,7 @@
 
 /* Lower frame F.  */
 
+void
 x_lower_frame (f)
      struct frame *f;
 {
@@ -5741,6 +5758,7 @@
    but it will become visible later when the window manager
    finishes with it.  */
 
+void
 x_make_frame_visible (f)
      struct frame *f;
 {
@@ -5869,6 +5887,7 @@
 
 /* Make the frame visible (mapped and not iconified).  */
 
+void
 x_make_frame_invisible (f)
      struct frame *f;
 {
@@ -5951,6 +5970,7 @@
 
 /* Change window state from mapped to iconified. */
 
+void
 x_iconify_frame (f)
      struct frame *f;
 {
@@ -6059,6 +6079,7 @@
 
 /* Destroy the X window of frame F.  */
 
+void
 x_destroy_window (f)
      struct frame *f;
 {
@@ -6130,6 +6151,7 @@
    If USER_POSITION is nonzero, we set the USPosition
    flag (this is useful when FLAGS is 0).  */
 
+void
 x_wm_set_size_hint (f, flags, user_position)
      struct frame *f;
      long flags;
@@ -6273,6 +6295,7 @@
 }
 
 /* Used for IconicState or NormalState */
+void
 x_wm_set_window_state (f, state)
      struct frame *f;
      int state;
@@ -6292,6 +6315,7 @@
 #endif /* not USE_X_TOOLKIT */
 }
 
+void
 x_wm_set_icon_pixmap (f, pixmap_id)
      struct frame *f;
      int pixmap_id;
@@ -6341,6 +6365,7 @@
 #endif /* not USE_X_TOOLKIT */
 }
 
+void
 x_wm_set_icon_position (f, icon_x, icon_y)
      struct frame *f;
      int icon_x, icon_y;
@@ -7161,6 +7186,7 @@
 
 /* Set up use of X before we make the first connection.  */
 
+void
 x_initialize ()
 {
   clear_frame_hook = XTclear_frame;