From: eggert@twinsun.COM (Paul Eggert)
Subject: oleo 1.2 has many C function prototype problems
Organization: GNUs Not Usenet
Distribution: gnu
Date: Fri, 1 Jan 1993 18:13:24 GMT

oleo 1.2 has a lot of problems with ANSI C function prototypes.

* If __STDC__ is defined, oleo often uses declarations and definitions of the
  following form:

	int f (CELLREF); /* declaration */
	int f (x) CELLREF x; { ... } /* definition */

  But ANSI C does not allow this, since CELLREF is a short type like `unsigned
  short', and the old-style definition promotes CELLREF to `int'.  Compiling
  oleo with `gcc -ansi -pedantic' shows many instances of this problem; the
  patch below contains several fixes but I'm not sure I caught all instances
  of the problem.  This problem can cause oleo to fail on hosts that use
  different calling conventions for passing shorts vs ints.
 
* oleo specifies incorrect function prototypes for calloc, malloc, and getenv.
  This can cause compilation to fail in an ANSI C environment.

* The ANSI C way of declaring a function with no arguments is
  `int f (void);'.  Unfortunately, oleo uses the style `int f ();';
  this causes the C compiler to not check the types of arguments of calls to f.

* The 3rd arg of hash_insert should be VOIDSTAR, not char *.

* oleo doesn't declare function prototypes for for_all_vars, hash_insert,
  index, rindex.

* oleo declares ck_fopen but never uses it.

Here is a patch.

Thu Dec 31 15:31:32 1992  Paul Eggert  (eggert@twinsun.com)

	* decompile.c (decomp): Use prototoype when defining in ANSI C, since
	the argument type CELLREF will be promoted otherwise, and ANSI C does
	not allow mixing old-style definitions with prototype declarations
	when argument types are promoted.
	* display.c (cell_display_of, pr_display_cell): Likewise.
	* io-curses.c (_io_pr_cell_win, move_cursor_to): Likewise.
	* io-term.c (set_cell_formula): Likewise.
	* io-utils.c (cell_value_string, cell_name, col_to_str): Likewise.
	* io-x11.c (xio_pr_cell_win): Likewise.
	* lists.c (find_cell, find_or_make_cell): Likewise.
	* ref.c (new_value, set_new_value, read_new_value, move_cell,
	copy_cell, add_ref, flush_range_ref, add_ref_fm, flush_ref_fm,
	push_cell): Likewise.
	* regions.c (set_rng): Likewise.
	* window.c (win_label_cols, io_pr_cell, io_move_cell_cursor): Likewise.

	* cell.h, font.h, global.h, io-abstract.h, io-generic.h, io-term.c,
	io-term.h, io-utils.h, list.h, lists.h, oleofile.h, ref.h, regions.h,
	sc.h, sylk.h, utils.h, window.h: If __STDC__, declare zero-argument
	functions using `(void)', not `()'.

	* global.h (for_all_vars, hash_insert, index, rindex): Declare
	argument types if __STDC__.

	* hash.c (hash_insert): 3rd arg is VOIDSTAR, not char *.

	* io-term.c: Declare prototype for getenv,
	move_region, format_area, open_window, close_window, goto_window.

	* io-x11.c (getenv): Argument is const char *, not char *.

	* ref.c (for_all_vars): Use prototype for argument if __STDC__.

	* utils.h (abort, malloc, calloc): Correct prototypes to agree with
	ANSI C.
	* utils.h (ck_fopen): Delete unused declaration.

===================================================================
RCS file: RCS/cell.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** cell.h	1992/12/31 05:10:18	1.2
--- cell.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 143,153 ****
  extern CELL *find_or_make_cell (CELLREF, CELLREF);
  extern void find_cells_in_range (struct rng *);
  extern void make_cells_in_range (struct rng *);
! extern CELL *next_cell_in_range ();
  extern CELL *next_row_col_in_range (CELLREF *, CELLREF *);
! extern void no_more_cells ();
  extern char *decomp (CELLREF, CELLREF, CELL *);
! extern void decomp_free ();
  #else
  extern CELL *find_cell ();
  extern CELL *find_or_make_cell ();
--- 143,153 ----
  extern CELL *find_or_make_cell (CELLREF, CELLREF);
  extern void find_cells_in_range (struct rng *);
  extern void make_cells_in_range (struct rng *);
! extern CELL *next_cell_in_range (void);
  extern CELL *next_row_col_in_range (CELLREF *, CELLREF *);
! extern void no_more_cells (void);
  extern char *decomp (CELLREF, CELLREF, CELL *);
! extern void decomp_free (void);
  #else
  extern CELL *find_cell ();
  extern CELL *find_or_make_cell ();
===================================================================
RCS file: RCS/decompile.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** decompile.c	1992/12/31 05:10:15	1.2
--- decompile.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 565,575 ****
--- 565,580 ----
  /* Actual entry points to this file */
  /* decomp(row, col, cell) returns a string that can be byte_compiled to create
     cell->formula  decomp_free() frees up the allocated string */
+ #if __STDC__
  char *
+ decomp (CELLREF r, CELLREF c, CELL *cell)
+ #else
+ char *
  decomp (r, c, cell)
       CELLREF r;
       CELLREF c;
       CELL *cell;
+ #endif
  {
    struct pr_node *ret;
    char *str;
===================================================================
RCS file: RCS/display.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** display.c	1992/12/28 05:04:08	1.2
--- display.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 21,31 ****
--- 21,36 ----
  #include "cell.h"
  #include "io-utils.h"
  
+ #if __STDC__
  struct cell_display *
+ cell_display_of (struct display *disp, CELLREF r, CELLREF c)
+ #else
+ struct cell_display *
  cell_display_of (disp, r, c)
       struct display *disp;
       CELLREF r;
       CELLREF c;
+ #endif
  {
    int cols = disp->range.hc - disp->range.lc + 1;
    r -= disp->range.lr;
***************
*** 69,80 ****
--- 74,90 ----
      }
  }
  
+ #if __STDC__
+ int
+ pr_display_cell (struct display *disp, CELLREF r, CELLREF c, CELL *cp)
+ #else
  int
  pr_display_cell (disp, r, c, cp)
       struct display *disp;
       CELLREF r;
       CELLREF c;
       CELL *cp;
+ #endif
  {
    int cols = disp->range.hc - disp->range.lc + 1;
    struct cell_display *cd =
===================================================================
RCS file: RCS/font.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** font.h	1992/12/28 05:00:39	1.2
--- font.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 47,58 ****
   */
  
  #ifdef __STDC__
! extern void init_fonts ();
! extern void flush_fonts ();
  extern struct font_memo *intern_font (char *spec);
  extern void define_font (char * spec);
  extern void set_area_font (struct rng *, struct font_memo *);
! extern struct font_memo *default_font ();
  extern void set_ps_font_cmd (char *);
  extern void set_line_to_nice_font_name (struct line *, struct font_memo *);
  #else
--- 47,58 ----
   */
  
  #ifdef __STDC__
! extern void init_fonts (void);
! extern void flush_fonts (void);
  extern struct font_memo *intern_font (char *spec);
  extern void define_font (char * spec);
  extern void set_area_font (struct rng *, struct font_memo *);
! extern struct font_memo *default_font (void);
  extern void set_ps_font_cmd (char *);
  extern void set_line_to_nice_font_name (struct line *, struct font_memo *);
  #else
===================================================================
RCS file: RCS/global.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** global.h	1992/12/28 05:00:40	1.2
--- global.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 137,144 ****
  
  #ifdef __STDC__
  
! extern const char *index ();
! extern const char *rindex ();
  extern char *strdup (const char *);
  extern const char *strstr (const char *, const char *);
  extern double astof (char **);
--- 137,144 ----
  
  #ifdef __STDC__
  
! extern const char *index (char *, int);
! extern const char *rindex (char *, int);
  extern char *strdup (const char *);
  extern const char *strstr (const char *, const char *);
  extern double astof (char **);
***************
*** 157,163 ****
  extern void add_timer_ref (int);
  extern void add_ref_to (int);
  
! extern char *hash_insert ();
  
  extern char *jst_to_str (int);
  extern char *fmt_to_str (int);
--- 157,164 ----
  extern void add_timer_ref (int);
  extern void add_ref_to (int);
  
! struct hash_control; /* in case it hasn't been declared yet */
! extern char *hash_insert (struct hash_control *, char *, VOIDSTAR);
  
  extern char *jst_to_str (int);
  extern char *fmt_to_str (int);
***************
*** 168,174 ****
  
  extern char *flt_to_str (double);
  extern void push_refs (struct ref_fm *);
! extern void no_more_cells ();
  
  extern char *range_name (struct rng *);
  extern char *cell_name (CELLREF, CELLREF);
--- 169,175 ----
  
  extern char *flt_to_str (double);
  extern void push_refs (struct ref_fm *);
! extern void no_more_cells (void);
  
  extern char *range_name (struct rng *);
  extern char *cell_name (CELLREF, CELLREF);
***************
*** 177,183 ****
  
  extern unsigned char parse_cell_or_range (char **, struct rng *);
  
! extern void for_all_vars (void (*)());
  #else
  
  extern char *index ();
--- 178,185 ----
  
  extern unsigned char parse_cell_or_range (char **, struct rng *);
  
! struct var; /* in case it hasn't been declared yet */
! extern void for_all_vars (void (*)(char *, struct var *));
  #else
  
  extern char *index ();
===================================================================
RCS file: RCS/hash.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** hash.c	1992/12/31 05:09:59	1.2
--- hash.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 408,414 ****
  hash_insert (handle, string, value)
       register struct hash_control *handle;
       register char *string;
!      register char *value;
  {
    register struct hash_entry *entry;
    register char *retval;
--- 408,414 ----
  hash_insert (handle, string, value)
       register struct hash_control *handle;
       register char *string;
!      register VOIDSTAR value;
  {
    register struct hash_entry *entry;
    register char *retval;
===================================================================
RCS file: RCS/io-abstract.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** io-abstract.h	1992/12/28 05:13:11	1.2
--- io-abstract.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 36,87 ****
  #endif
  
  #ifdef __STDC__
! EXTERN void (*io_open_display) ();
! EXTERN void (*io_redisp) ();	/* Refresh the existing image. */
! EXTERN void (*io_repaint) ();	/* $$$ Recompute the image. */
  EXTERN void (*io_repaint_win) (struct window *);
! EXTERN void (*io_close_display) ();
  
  /*
   * Low level input.
   */
! EXTERN int (*io_input_avail) ();/* How many chars can be read? */
  EXTERN void (*io_scan_for_input) (int ok_to_block);
! EXTERN void (*io_wait_for_input) ();
  EXTERN int (*io_read_kbd) (VOLATILE char *buf, int size);
  
  /* A curses compatible interface.  These have no effect on low level
     calls except to consume characters which io_read_kbd might
     otherwise return. */
  EXTERN void (*io_nodelay) (int);
! EXTERN int (*io_getch) ();
  
  /* High level i/o. */
  
  /* Input and status areas: */
! EXTERN void (*io_clear_input_before) ();
! EXTERN void (*io_clear_input_after) ();
! EXTERN void (*io_update_status) ();
  EXTERN void (*io_info_msg) (char *,...);
  EXTERN void (*io_error_msg) (char *,...);
  EXTERN int (*io_get_chr) (char *prompt);
  EXTERN int (*io_get_line) (char *prompt, struct line * line);
  
  /* Multi-line txt messages. */
! EXTERN void (*io_text_start) ();
  EXTERN void (*io_text_line) (char *,...);
! EXTERN void (*io_text_finish) ();
  
  /* Cell values */
! EXTERN void (*io_hide_cell_cursor) ();
! EXTERN void (*io_display_cell_cursor) ();
  EXTERN void (*io_pr_cell_win) (struct window *,
  			       CELLREF, CELLREF,
  			       CELL *);
  
  /* The terminal's cursor may be in the current cell or the input area. */
! EXTERN void (*io_cellize_cursor) ();
! EXTERN void (*io_inputize_cursor) ();
  #else
  EXTERN void (*io_open_display) ();
  EXTERN void (*io_redisp) ();	/* Refresh the existing image. */
--- 36,87 ----
  #endif
  
  #ifdef __STDC__
! EXTERN void (*io_open_display) (void);
! EXTERN void (*io_redisp) (void);	/* Refresh the existing image. */
! EXTERN void (*io_repaint) (void);	/* $$$ Recompute the image. */
  EXTERN void (*io_repaint_win) (struct window *);
! EXTERN void (*io_close_display) (void);
  
  /*
   * Low level input.
   */
! EXTERN int (*io_input_avail) (void);/* How many chars can be read? */
  EXTERN void (*io_scan_for_input) (int ok_to_block);
! EXTERN void (*io_wait_for_input) (void);
  EXTERN int (*io_read_kbd) (VOLATILE char *buf, int size);
  
  /* A curses compatible interface.  These have no effect on low level
     calls except to consume characters which io_read_kbd might
     otherwise return. */
  EXTERN void (*io_nodelay) (int);
! EXTERN int (*io_getch) (void);
  
  /* High level i/o. */
  
  /* Input and status areas: */
! EXTERN void (*io_clear_input_before) (void);
! EXTERN void (*io_clear_input_after) (void);
! EXTERN void (*io_update_status) (void);
  EXTERN void (*io_info_msg) (char *,...);
  EXTERN void (*io_error_msg) (char *,...);
  EXTERN int (*io_get_chr) (char *prompt);
  EXTERN int (*io_get_line) (char *prompt, struct line * line);
  
  /* Multi-line txt messages. */
! EXTERN void (*io_text_start) (void);
  EXTERN void (*io_text_line) (char *,...);
! EXTERN void (*io_text_finish) (void);
  
  /* Cell values */
! EXTERN void (*io_hide_cell_cursor) (void);
! EXTERN void (*io_display_cell_cursor) (void);
  EXTERN void (*io_pr_cell_win) (struct window *,
  			       CELLREF, CELLREF,
  			       CELL *);
  
  /* The terminal's cursor may be in the current cell or the input area. */
! EXTERN void (*io_cellize_cursor) (void);
! EXTERN void (*io_inputize_cursor) (void);
  #else
  EXTERN void (*io_open_display) ();
  EXTERN void (*io_redisp) ();	/* Refresh the existing image. */
===================================================================
RCS file: RCS/io-curses.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** io-curses.c	1992/12/28 05:04:08	1.2
--- io-curses.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 1044,1055 ****
--- 1044,1059 ----
  #undef MORE
      }
  
+ #if __STDC__
+   static void move_cursor_to (struct window *win, CELLREF r, CELLREF c, int dn)
+ #else
    static void
      move_cursor_to (win, r, c, dn)
    struct window *win;
    CELLREF r;
    CELLREF c;
    int dn;
+ #endif
    {
      int cc;
      int cell_cursor_col;
***************
*** 1320,1330 ****
--- 1324,1338 ----
    }
  
  
+ #if __STDC__
+   static void _io_pr_cell_win (struct window *win, CELLREF r, CELLREF c, CELL *cp)
+ #else
    static void _io_pr_cell_win (win, r, c, cp)
    struct window *win;
    CELLREF r;
    CELLREF c;
    CELL *cp;
+ #endif
    {
      int glowing;
      int lenstr;
===================================================================
RCS file: RCS/io-generic.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** io-generic.h	1992/12/28 05:13:10	1.2
--- io-generic.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 43,56 ****
  extern void (*read_file) (FILE *, int);
  extern void (*write_file) (FILE *, struct rng *);
  extern int (*set_file_opts) (int, char *);
! extern void (*show_file_opts) ();
  
! extern int get_chr ();		/* read from kbd or macro */
  extern void open_window (char *);	/* For syntax, see HOW-TO-USE */
  extern void close_window (char *);
  extern void goto_window (char *);
  extern int set_window_option (int set_opt, char *text);
! extern void show_window_options ();
  #else
  extern void (*read_file) ();
  extern void (*write_file) ();
--- 43,56 ----
  extern void (*read_file) (FILE *, int);
  extern void (*write_file) (FILE *, struct rng *);
  extern int (*set_file_opts) (int, char *);
! extern void (*show_file_opts) (void);
  
! extern int get_chr (void);		/* read from kbd or macro */
  extern void open_window (char *);	/* For syntax, see HOW-TO-USE */
  extern void close_window (char *);
  extern void goto_window (char *);
  extern int set_window_option (int set_opt, char *text);
! extern void show_window_options (void);
  #else
  extern void (*read_file) ();
  extern void (*write_file) ();
===================================================================
RCS file: RCS/io-term.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** io-term.c	1992/12/31 05:09:55	1.2
--- io-term.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 76,82 ****
  
  
  #ifdef __STDC__
! extern char *getenv ();
  extern unsigned ualarm (unsigned int, unsigned int);
  #else
  extern char *getenv ();
--- 76,82 ----
  
  
  #ifdef __STDC__
! extern char *getenv (const char *);
  extern unsigned ualarm (unsigned int, unsigned int);
  #else
  extern char *getenv ();
***************
*** 110,116 ****
  /* Routines for implementing user commands */
  int global_cmd (int);
  void set_options (char *);
! void play_cell ();
  
  /* Backends for other functions */
  static int do_set_option (char *);
--- 110,116 ----
  /* Routines for implementing user commands */
  int global_cmd (int);
  void set_options (char *);
! void play_cell (void);
  
  /* Backends for other functions */
  static int do_set_option (char *);
***************
*** 121,127 ****
  
  int main (int, char **);
  void map_chr (int);
! extern void clear_spreadsheet ();
  char *cell_name (CELLREF, CELLREF);
  char *range_name (struct rng *);
  char *fmt_to_str (int);
--- 121,127 ----
  
  int main (int, char **);
  void map_chr (int);
! extern void clear_spreadsheet (void);
  char *cell_name (CELLREF, CELLREF);
  char *range_name (struct rng *);
  char *fmt_to_str (int);
***************
*** 129,196 ****
  char *col_to_str (CELLREF);
  static void got_sigint (int);
  /* The user commands that are defined in this file. . . */
! extern void copy_region ();
! extern void copy_values_region ();
! extern void set_format ();
! extern void move_region ();
! extern void delete_region ();
! extern void insert_row ();
! extern void insert_col ();
! extern void delete_row ();
! extern void delete_col ();
! extern void format_area ();
! extern void open_window ();
! extern void close_window ();
! extern void hsplit_window ();
! extern void vsplit_window ();
! extern void delete_window ();
! extern void delete_other_windows ();
! extern void goto_window ();
! extern void other_window ();
  extern void print_region (struct rng *, char *);
  extern void psprint_region_cmd (FILE *, struct rng *);
  
  static void do_debug (char *);
! static void end_macro ();
! static void do_break_cmd ();
! static void set_default ();
! static void quit_cmd ();
  static void set_usr_fmt (char *);
  static void set_var (char *);
  static void show_var (char *);
! static void show_all_var ();
  static void write_variables (FILE *);
  static void read_variables (FILE *);
! static void recalc_cmd ();
  static void bind_key_cmd (char *);
! static void desc_key_cmd ();
  static void where_is_cmd (char *);
  static void read_cmds_cmd (FILE *);
  static void write_keys_cmd (FILE *);
  static void write_cmd (FILE *);
  static void read_cmd (FILE *);
  static void read_merge_cmd (FILE *);
! static void kill_all_cmd ();
  static void sort_region_cmd (char *);
  static void write_reg_cmd (FILE *, struct rng *);
! static void start_macro ();
  void execute_cmd (char *);
! static void interact_macro_cmd ();
  static void goto_region (struct rng *);
! static void upper_left ();
! static void lower_left ();
! static void upper_right ();
! static void lower_right ();
! extern void exchange_point_and_mark ();
! static void mark_cell_cmd ();
! static void unmark_cmd ();
  static void do_input_cmd (int, int);
  static void set_region_formula (char *, struct rng *);
  static void set_cell_formula (char *, CELLREF, CELLREF);
! static void format_cell_cmd ();
! static void kill_cell_cmd ();
  static void digit_cmd (int);
! static void show_options ();
  static void bound_macro (int);
  static void make_keymap (char *);
  static void set_cell_font_cmd (char *);
--- 129,196 ----
  char *col_to_str (CELLREF);
  static void got_sigint (int);
  /* The user commands that are defined in this file. . . */
! extern void copy_region (void);
! extern void copy_values_region (void);
! extern void set_format (void);
! extern void move_region (struct rng *, struct rng *);
! extern void delete_region (void);
! extern void insert_row (void);
! extern void insert_col (void);
! extern void delete_row (void);
! extern void delete_col (void);
! extern void format_area (struct rng *);
! extern void open_window (char *);
! extern void close_window (char *);
! extern void hsplit_window (void);
! extern void vsplit_window (void);
! extern void delete_window (void);
! extern void delete_other_windows (void);
! extern void goto_window (char *);
! extern void other_window (void);
  extern void print_region (struct rng *, char *);
  extern void psprint_region_cmd (FILE *, struct rng *);
  
  static void do_debug (char *);
! static void end_macro (void);
! static void do_break_cmd (void);
! static void set_default (void);
! static void quit_cmd (void);
  static void set_usr_fmt (char *);
  static void set_var (char *);
  static void show_var (char *);
! static void show_all_var (void);
  static void write_variables (FILE *);
  static void read_variables (FILE *);
! static void recalc_cmd (void);
  static void bind_key_cmd (char *);
! static void desc_key_cmd (void);
  static void where_is_cmd (char *);
  static void read_cmds_cmd (FILE *);
  static void write_keys_cmd (FILE *);
  static void write_cmd (FILE *);
  static void read_cmd (FILE *);
  static void read_merge_cmd (FILE *);
! static void kill_all_cmd (void);
  static void sort_region_cmd (char *);
  static void write_reg_cmd (FILE *, struct rng *);
! static void start_macro (void);
  void execute_cmd (char *);
! static void interact_macro_cmd (void);
  static void goto_region (struct rng *);
! static void upper_left (void);
! static void lower_left (void);
! static void upper_right (void);
! static void lower_right (void);
! extern void exchange_point_and_mark (void);
! static void mark_cell_cmd (void);
! static void unmark_cmd (void);
  static void do_input_cmd (int, int);
  static void set_region_formula (char *, struct rng *);
  static void set_cell_formula (char *, CELLREF, CELLREF);
! static void format_cell_cmd (void);
! static void kill_cell_cmd (void);
  static void digit_cmd (int);
! static void show_options (void);
  static void bound_macro (int);
  static void make_keymap (char *);
  static void set_cell_font_cmd (char *);
***************
*** 198,210 ****
  static void scan_cell_cursor (int);
  static void shift_cell_cursor (int);
  static void scroll_cell_cursor (int);
! static void recenter_cur_win ();
! static void repaint ();
! static void mouse_goto_cmd ();
! static void mouse_mark_cmd ();
! static void mouse_mark_and_goto_cmd ();
  static void set_page_size_cmd (char *);
! void toggle_load_hooks ();
  void read_file_and_run_hooks (FILE *, int);
  
  #ifdef HAVE_X11_X_H
--- 198,210 ----
  static void scan_cell_cursor (int);
  static void shift_cell_cursor (int);
  static void scroll_cell_cursor (int);
! static void recenter_cur_win (void);
! static void repaint (void);
! static void mouse_goto_cmd (void);
! static void mouse_mark_cmd (void);
! static void mouse_mark_and_goto_cmd (void);
  static void set_page_size_cmd (char *);
! void toggle_load_hooks (void);
  void read_file_and_run_hooks (FILE *, int);
  
  #ifdef HAVE_X11_X_H
***************
*** 4283,4292 ****
--- 4283,4297 ----
        }
  }
  
+ #if __STDC__
  static void
+ set_cell_formula (char * str, CELLREF row, CELLREF col)
+ #else
+ static void
  set_cell_formula (str, row, col)
       char * str;
       CELLREF row, col;
+ #endif
  {
    char * error = new_value (row, col, str);
    if (error)
===================================================================
RCS file: RCS/io-term.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** io-term.h	1992/11/28 03:28:59	1.2
--- io-term.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 28,34 ****
  
  #ifdef __STDC__
  extern int global_cmd (int);
! extern int real_get_chr ();
  extern void read_mp_usr_fmt (char *);
  extern void read_mp_options (char *);
  extern void write_mp_options (FILE *);
--- 28,34 ----
  
  #ifdef __STDC__
  extern int global_cmd (int);
! extern int real_get_chr (void);
  extern void read_mp_usr_fmt (char *);
  extern void read_mp_options (char *);
  extern void write_mp_options (FILE *);
===================================================================
RCS file: RCS/io-utils.c,v
retrieving revision 1.2.1.1
retrieving revision 1.2.1.2
diff -c -r1.2.1.1 -r1.2.1.2
*** io-utils.c	1992/12/31 13:16:32	1.2.1.1
--- io-utils.c	1992/12/31 15:31:32	1.2.1.2
***************
*** 364,373 ****
--- 364,378 ----
  /* Return the value of ROW,COL in a human-readable fashion
     In paticular, strings have "" around them, and are \\ed
   */
+ #if __STDC__
  char *
+ cell_value_string (CELLREF row, CELLREF col)
+ #else
+ char *
  cell_value_string (row, col)
       CELLREF row;
       CELLREF col;
+ #endif
  {
    CELL *cp;
  
***************
*** 907,916 ****
--- 912,926 ----
  
  /* Functions for printing out the names of cells and ranges */
  
+ #if __STDC__
+ char *
+ cell_name (CELLREF rr, CELLREF cc)
+ #else
  char *
  cell_name (rr, cc)
       CELLREF rr;
       CELLREF cc;
+ #endif
  {
    static char strs[2][20];
    static num = 0;
***************
*** 1000,1008 ****
--- 1010,1023 ----
  }
  
  
+ #if __STDC__
+ char *
+ col_to_str (CELLREF col)
+ #else
  char *
  col_to_str (col)
       CELLREF col;
+ #endif
  {
    static char strs[2][10];
    static num;
===================================================================
RCS file: RCS/io-utils.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** io-utils.h	1992/11/28 03:28:59	1.2
--- io-utils.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 22,34 ****
  #include "cell.h"
  
  #ifdef __STDC__
! extern void clear_spreadsheet ();
  extern char *print_cell (CELL *);
  extern char *cell_value_string (CELLREF r, CELLREF c);
  extern char *col_to_str (CELLREF);
  extern char *flt_to_str (double);
  char *backslash_a_string (char *, int);
! extern int user_set_fmts ();
  extern char *cell_name (CELLREF, CELLREF);
  extern char *range_name (struct rng *);
  extern char *new_var_value (char *, int, char *);
--- 22,34 ----
  #include "cell.h"
  
  #ifdef __STDC__
! extern void clear_spreadsheet (void);
  extern char *print_cell (CELL *);
  extern char *cell_value_string (CELLREF r, CELLREF c);
  extern char *col_to_str (CELLREF);
  extern char *flt_to_str (double);
  char *backslash_a_string (char *, int);
! extern int user_set_fmts (void);
  extern char *cell_name (CELLREF, CELLREF);
  extern char *range_name (struct rng *);
  extern char *new_var_value (char *, int, char *);
===================================================================
RCS file: RCS/io-x11.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** io-x11.c	1992/12/30 02:17:42	1.2
--- io-x11.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 51,57 ****
  #ifdef __STDC__
  extern char * x_get_string_resource (XrmDatabase, char *, char *);
  extern XrmDatabase x_load_resources (Display *, char *, char *);
! extern char * getenv (char *);
  #else
  extern char * x_get_string_resource ();
  extern XrmDatabase x_load_resources ();
--- 51,57 ----
  #ifdef __STDC__
  extern char * x_get_string_resource (XrmDatabase, char *, char *);
  extern XrmDatabase x_load_resources (Display *, char *, char *);
! extern char * getenv (const char *);
  #else
  extern char * x_get_string_resource ();
  extern XrmDatabase x_load_resources ();
***************
*** 1791,1802 ****
--- 1791,1807 ----
  }
  
  
+ #if __STDC__
  static void
+ xio_pr_cell_win (struct window *win, CELLREF r, CELLREF c, CELL *cp)
+ #else
+ static void
  xio_pr_cell_win (win, r, c, cp)
       struct window *win;
       CELLREF r;
       CELLREF c;
       CELL *cp;
+ #endif
  {
    struct x_window *xwin = x_win (thePort, win, 0);
    struct display *disp = &xwin->display;
===================================================================
RCS file: RCS/list.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** list.h	1992/11/28 03:29:00	1.2
--- list.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 22,28 ****
  extern void list_read_file (FILE *, int);
  extern void list_write_file (FILE *, struct rng *);
  extern int list_set_options (int, char *);
! extern void list_show_options ();
  #else
  extern void list_read_file ();
  extern void list_write_file ();
--- 22,28 ----
  extern void list_read_file (FILE *, int);
  extern void list_write_file (FILE *, struct rng *);
  extern int list_set_options (int, char *);
! extern void list_show_options (void);
  #else
  extern void list_read_file ();
  extern void list_write_file ();
===================================================================
RCS file: RCS/lists.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** lists.c	1992/12/31 05:09:47	1.2
--- lists.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 470,479 ****
--- 470,484 ----
    flush_fonts ();
  }
  
+ #if __STDC__
  struct cell *
+ find_cell (CELLREF row, CELLREF col)
+ #else
+ struct cell *
  find_cell (row, col)
       CELLREF row;
       CELLREF col;
+ #endif
  {
    void **v;
  
***************
*** 481,490 ****
--- 486,500 ----
    return v ? find (row, *v, sizeof (struct cell)) : 0;
  }
  
+ #if __STDC__
+ struct cell *
+ find_or_make_cell (CELLREF row, CELLREF col)
+ #else
  struct cell *
  find_or_make_cell (row, col)
       CELLREF row;
       CELLREF col;
+ #endif
  {
    struct list **v;
  
===================================================================
RCS file: RCS/lists.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** lists.h	1992/12/28 05:00:43	1.2
--- lists.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 21,33 ****
  #include "global.h"
  
  #ifdef __STDC__
! extern CELLREF highest_row ();
! extern CELLREF highest_col ();
  extern unsigned short next_width (CELLREF *);
  extern void list_read_file (FILE *, int);
  extern void list_write_file (FILE *, struct rng *);
  extern int list_set_options (int, char *);
! extern void list_show_options ();
  extern int get_scaled_width (CELLREF c);
  extern int get_scaled_height (CELLREF c);
  extern int get_width (CELLREF c);
--- 21,33 ----
  #include "global.h"
  
  #ifdef __STDC__
! extern CELLREF highest_row (void);
! extern CELLREF highest_col (void);
  extern unsigned short next_width (CELLREF *);
  extern void list_read_file (FILE *, int);
  extern void list_write_file (FILE *, struct rng *);
  extern int list_set_options (int, char *);
! extern void list_show_options (void);
  extern int get_scaled_width (CELLREF c);
  extern int get_scaled_height (CELLREF c);
  extern int get_width (CELLREF c);
***************
*** 35,42 ****
  extern void set_width (CELLREF, unsigned short);
  extern void set_height (CELLREF, unsigned short);
  extern void find_widths (CELLREF, CELLREF);
! extern void flush_everything ();
! extern void flush_all_timers ();
  extern CELLREF max_row (CELLREF);
  extern CELLREF max_col (CELLREF);
  extern void shift_widths (int, CELLREF, CELLREF);
--- 35,42 ----
  extern void set_width (CELLREF, unsigned short);
  extern void set_height (CELLREF, unsigned short);
  extern void find_widths (CELLREF, CELLREF);
! extern void flush_everything (void);
! extern void flush_all_timers (void);
  extern CELLREF max_row (CELLREF);
  extern CELLREF max_col (CELLREF);
  extern void shift_widths (int, CELLREF, CELLREF);
===================================================================
RCS file: RCS/oleofile.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** oleofile.h	1992/11/28 03:29:00	1.2
--- oleofile.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 22,28 ****
  extern void oleo_read_file (FILE *, int);
  extern void oleo_write_file (FILE *, struct rng *);
  extern int oleo_set_options (int, char *);
! extern void oleo_show_options ();
  #else
  extern void oleo_read_file ();
  extern void oleo_write_file ();
--- 22,28 ----
  extern void oleo_read_file (FILE *, int);
  extern void oleo_write_file (FILE *, struct rng *);
  extern int oleo_set_options (int, char *);
! extern void oleo_show_options (void);
  #else
  extern void oleo_read_file ();
  extern void oleo_write_file ();
===================================================================
RCS file: RCS/ref.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** ref.c	1992/12/31 05:09:32	1.2
--- ref.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 165,175 ****
--- 165,180 ----
  /* new_value() calls set_cell, but refuses to change locked cells, and
     updates and prints the results.  It returns an error msg on error. . .
   */
+ #if __STDC__
  char *
+ new_value (CELLREF row, CELLREF col, char *string)
+ #else
+ char *
  new_value (row, col, string)
       CELLREF row;
       CELLREF col;
       char *string;
+ #endif
  {
    CELL *cp;
  
***************
*** 195,206 ****
--- 200,216 ----
  }
  
  /* This sets the cell to a constant, stored in VALUE, whose type is in TYPE */
+ #if __STDC__
+ char *
+ set_new_value (CELLREF row, CELLREF col, int type, union vals *value)
+ #else
  char *
  set_new_value (row, col, type, value)
       CELLREF row;
       CELLREF col;
       int type;
       union vals *value;
+ #endif
  {
    CELL *cp;
    extern int default_lock;
***************
*** 273,284 ****
--- 283,299 ----
  /* We're reading in a cell, whose formula is FORM, and whose current value
     is VAL.  Parse both of them. . .  (Parsing of VAL is quite primitive)
   */
+ #if __STDC__
+ char *
+ read_new_value (CELLREF row, CELLREF col, char *form, char *val)
+ #else
  char *
  read_new_value (row, col, form, val)
       CELLREF row;
       CELLREF col;
       char *form;
       char *val;
+ #endif
  {
    unsigned char *new_bytes;
    extern double __plinf, __neinf, __nan;
***************
*** 398,409 ****
--- 413,429 ----
     we may *not* want to call move_outside. . .
   */
  
+ #if __STDC__
+ void
+ move_cell (CELLREF rf, CELLREF cf, CELLREF rt, CELLREF ct)
+ #else
  void
  move_cell (rf, cf, rt, ct)
       CELLREF rf;
       CELLREF cf;
       CELLREF rt;
       CELLREF ct;
+ #endif
  {
    CELL *cpf;
  
***************
*** 497,508 ****
--- 517,533 ----
    my_cell = 0;
  }
  
+ #if __STDC__
  void
+ copy_cell (CELLREF rf, CELLREF cf, CELLREF rt, CELLREF ct)
+ #else
+ void
  copy_cell (rf, cf, rt, ct)
       CELLREF rf;
       CELLREF cf;
       CELLREF rt;
       CELLREF ct;
+ #endif
  {
    CELL *cpf;
  
***************
*** 852,861 ****
--- 877,891 ----
  
  /* --------- Routines for dealing with cell references to other cells ------ */
  
+ #if __STDC__
  void
+ add_ref (CELLREF row, CELLREF col)
+ #else
+ void
  add_ref (row, col)
       CELLREF row;
       CELLREF col;
+ #endif
  {
    CELL *other_cell;
  
***************
*** 918,928 ****
--- 948,963 ----
  	} */
  }
  
+ #if __STDC__
+ static void
+ flush_range_ref (struct rng *rng, CELLREF rr, CELLREF cc)
+ #else
  static void
  flush_range_ref (rng, rr, cc)
       struct rng *rng;
       CELLREF rr;
       CELLREF cc;
+ #endif
  {
    CELL *other_cell;
  #ifndef SPLIT_REFS
***************
*** 1129,1139 ****
--- 1164,1179 ----
  /* This adds a from reference to a cells reference list.
   * Note that the ref_fm structures themselves are hash-consed.
   */
+ #if __STDC__
+ static void
+ add_ref_fm (struct ref_fm **where, CELLREF r, CELLREF c)
+ #else
  static void
  add_ref_fm (where, r, c)
       struct ref_fm **where;
       CELLREF r;
       CELLREF c;
+ #endif
  {
    struct ref_fm *from;
    int n;
***************
*** 1181,1191 ****
--- 1221,1236 ----
      flush_fm_ref (from);
  }
  
+ #if __STDC__
+ static void
+ flush_ref_fm (struct ref_fm **where, CELLREF r, CELLREF c)
+ #else
  static void
  flush_ref_fm (where, r, c)
       struct ref_fm **where;
       CELLREF r;
       CELLREF c;
+ #endif
  {
    struct ref_fm *from;
    int n;
***************
*** 2476,2485 ****
--- 2521,2535 ----
     intersecting branches in the dependency tree, however, it's close enough
     for most people.
   */
+ #if __STDC__
  void
+ push_cell (CELLREF row, CELLREF col)
+ #else
+ void
  push_cell (row, col)
       CELLREF row;
       CELLREF col;
+ #endif
  {
    struct pos *dup;
    CELL *cp;
***************
*** 2707,2713 ****
  
  void
  #ifdef __STDC__
! for_all_vars (void (*func) ())
  #else
  for_all_vars (func)
       void (*func) ();
--- 2757,2763 ----
  
  void
  #ifdef __STDC__
! for_all_vars (void (*func) (char *, struct var *))
  #else
  for_all_vars (func)
       void (*func) ();
===================================================================
RCS file: RCS/ref.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** ref.h	1992/11/28 03:29:01	1.2
--- ref.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 22,34 ****
  
  #ifdef __STDC__
  extern void add_var_ref (void *);
! extern int eval_next_cell ();
  extern struct var *find_var (char *, int);
  extern void push_cell (CELLREF, CELLREF);
  extern void push_refs (struct ref_fm *);
  extern struct var *find_or_make_var (char *, int);
  extern void add_range_ref (struct rng *);
! extern void flush_old_value ();
  extern void add_ref_to (int);
  extern char *set_new_value (CELLREF, CELLREF, int, union vals *);
  extern char *new_value (CELLREF, CELLREF, char *);
--- 22,34 ----
  
  #ifdef __STDC__
  extern void add_var_ref (void *);
! extern int eval_next_cell (void);
  extern struct var *find_var (char *, int);
  extern void push_cell (CELLREF, CELLREF);
  extern void push_refs (struct ref_fm *);
  extern struct var *find_or_make_var (char *, int);
  extern void add_range_ref (struct rng *);
! extern void flush_old_value (void);
  extern void add_ref_to (int);
  extern char *set_new_value (CELLREF, CELLREF, int, union vals *);
  extern char *new_value (CELLREF, CELLREF, char *);
===================================================================
RCS file: RCS/regions.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** regions.c	1992/12/31 05:09:27	1.2
--- regions.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 40,52 ****
--- 40,57 ----
  /* Take a struct rng (R) and init its elements to R1 C1 R2 C2, making sure
     they are put in in the right order.
   */
+ #if __STDC__
  void
+ set_rng (struct rng *r, CELLREF r1, CELLREF c1, CELLREF r2, CELLREF c2)
+ #else
+ void
  set_rng (r, r1, c1, r2, c2)
       struct rng *r;
       CELLREF r1;
       CELLREF c1;
       CELLREF r2;
       CELLREF c2;
+ #endif
  {
    if (r1 <= r2)
      {
===================================================================
RCS file: RCS/regions.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** regions.h	1992/12/28 05:00:46	1.2
--- regions.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 43,49 ****
  extern void set_rng (struct rng *, CELLREF, CELLREF, CELLREF, CELLREF);
  extern void lock_region (struct rng *, int);
  extern void format_region (struct rng *, int, int);
! extern void sort_region ();
  #else
  extern int cmp_cells ();
  extern void swp_cells ();
--- 43,49 ----
  extern void set_rng (struct rng *, CELLREF, CELLREF, CELLREF, CELLREF);
  extern void lock_region (struct rng *, int);
  extern void format_region (struct rng *, int, int);
! extern void sort_region (void);
  #else
  extern int cmp_cells ();
  extern void swp_cells ();
===================================================================
RCS file: RCS/sc.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** sc.h	1992/11/28 03:29:01	1.2
--- sc.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 24,30 ****
  extern void sc_read_file (FILE *,int);
  extern void sc_write_file (FILE *,struct rng *);
  extern  int sc_set_options (int, char *);
! extern void sc_show_options ();
  #else
  extern void sc_read_file ();
  extern void sc_write_file ();
--- 24,30 ----
  extern void sc_read_file (FILE *,int);
  extern void sc_write_file (FILE *,struct rng *);
  extern  int sc_set_options (int, char *);
! extern void sc_show_options (void);
  #else
  extern void sc_read_file ();
  extern void sc_write_file ();
===================================================================
RCS file: RCS/sylk.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** sylk.h	1992/12/28 05:00:50	1.2
--- sylk.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 24,30 ****
  extern void sylk_read_file (FILE *,int);
  extern void sylk_write_file (FILE *,struct rng *);
  extern  int sylk_set_options (int, char *);
! extern void sylk_show_options ();
  #else
  extern void sylk_read_file ();
  extern void sylk_write_file ();
--- 24,30 ----
  extern void sylk_read_file (FILE *,int);
  extern void sylk_write_file (FILE *,struct rng *);
  extern  int sylk_set_options (int, char *);
! extern void sylk_show_options (void);
  #else
  extern void sylk_read_file ();
  extern void sylk_write_file ();
===================================================================
RCS file: RCS/utils.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** utils.c	1992/12/31 05:45:45	1.2
--- utils.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 53,61 ****
  #endif
  
  #ifdef __STDC__
! extern void abort ();
! extern void *malloc (int);
! extern void *calloc (int, int);
  extern void *realloc (void *, size_t);
  char *strdup (CONST char *);
  #else
--- 53,61 ----
  #endif
  
  #ifdef __STDC__
! extern void abort (void);
! extern void *malloc (size_t);
! extern void *calloc (size_t, size_t);
  extern void *realloc (void *, size_t);
  char *strdup (CONST char *);
  #else
===================================================================
RCS file: RCS/utils.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** utils.h	1992/12/28 05:00:50	1.2
--- utils.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 34,40 ****
  #define ck_free free
  #define ck_remalloc(OLD, SIZE) \
    ((OLD) ? ck_realloc ((OLD), (SIZE)) : ck_malloc (SIZE))
- extern FILE *ck_fopen();
  
  extern void get_usr_stats (int, char **);
  extern void set_usr_stats (int, char **);
--- 34,39 ----
***************
*** 43,62 ****
  extern int string_to_char (char **);
  extern FILE *xopen_with_backup (const char *,const char *);
  extern int xclose (FILE *);
! extern char *err_msg ();
  extern char *mk_sprintf (char *, ...);
  
! extern void init_mem ();
! extern void init_eval ();
! extern void init_refs ();
! extern void init_cells ();
! extern VOIDSTAR init_stack ();
  
  struct rng;
  extern void panic_read_file (FILE *,int);
  extern void panic_write_file (FILE *,struct rng *);
  extern  int panic_set_options (int, char *);
! extern void panic_show_options ();
  
  extern VOIDSTAR pop_stack (VOIDSTAR);
  extern void push_stack (VOIDSTAR, VOIDSTAR);
--- 42,61 ----
  extern int string_to_char (char **);
  extern FILE *xopen_with_backup (const char *,const char *);
  extern int xclose (FILE *);
! extern char *err_msg (void);
  extern char *mk_sprintf (char *, ...);
  
! extern void init_mem (void);
! extern void init_eval (void);
! extern void init_refs (void);
! extern void init_cells (void);
! extern VOIDSTAR init_stack (void);
  
  struct rng;
  extern void panic_read_file (FILE *,int);
  extern void panic_write_file (FILE *,struct rng *);
  extern  int panic_set_options (int, char *);
! extern void panic_show_options (void);
  
  extern VOIDSTAR pop_stack (VOIDSTAR);
  extern void push_stack (VOIDSTAR, VOIDSTAR);
***************
*** 70,76 ****
  #define ck_free free
  #define ck_remalloc(OLD, SIZE) \
    ((OLD) ? ck_realloc ((OLD), (SIZE)) : ck_malloc (SIZE))
- extern FILE *ck_fopen();
  
  extern void get_usr_stats ();
  extern void set_usr_stats ();
--- 69,74 ----
===================================================================
RCS file: RCS/window.c,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** window.c	1992/12/28 05:04:07	1.2
--- window.c	1992/12/31 15:31:32	1.2.1.1
***************
*** 281,290 ****
--- 281,295 ----
  }
  
  
+ #if __STDC__
  int
+ win_label_cols (struct window * win, CELLREF hr)
+ #else
+ int
  win_label_cols (win, hr)
       struct window * win;
       CELLREF hr;
+ #endif
  {
    int lh;
  
***************
*** 769,779 ****
--- 774,789 ----
  }
  
  
+ #if __STDC__
+ void 
+ io_pr_cell (CELLREF r, CELLREF c, CELL *cp)
+ #else
  void 
  io_pr_cell (r, c, cp)
       CELLREF r;
       CELLREF c;
       CELL *cp;
+ #endif
  {
    struct window *win;
  
***************
*** 864,873 ****
--- 874,888 ----
    do_close_window (win - wins);
  }
  
+ #if __STDC__
+ void 
+ io_move_cell_cursor (CELLREF rr, CELLREF cc)
+ #else
  void 
  io_move_cell_cursor (rr, cc)
       CELLREF rr;
       CELLREF cc;
+ #endif
  {
    if (cwin->link != -1)
      shift_linked_window ((long) rr - curow, (long) cc - cucol);
===================================================================
RCS file: RCS/window.h,v
retrieving revision 1.2
retrieving revision 1.2.1.1
diff -c -r1.2 -r1.2.1.1
*** window.h	1992/12/28 05:00:51	1.2
--- window.h	1992/12/31 15:31:32	1.2.1.1
***************
*** 149,156 ****
  extern void io_scroll_cell_cursor (int dirn);
  extern void io_pr_cell (CELLREF r, CELLREF c, CELL *);
  extern void io_redo_region (struct rng * rng);
! extern void io_recenter_cur_win ();
! extern void io_recenter_all_win ();
  
  extern int win_label_rows (struct window * win);
  extern int win_label_cols (struct window * win, CELLREF last_row);
--- 149,156 ----
  extern void io_scroll_cell_cursor (int dirn);
  extern void io_pr_cell (CELLREF r, CELLREF c, CELL *);
  extern void io_redo_region (struct rng * rng);
! extern void io_recenter_cur_win (void);
! extern void io_recenter_all_win (void);
  
  extern int win_label_rows (struct window * win);
  extern int win_label_cols (struct window * win, CELLREF last_row);

Newsgroups: gnu.utils.bug