From d53bd20bd5d0f4e990615bc47d9c57a2b5c8ee4e Mon Sep 17 00:00:00 2001 From: christos Date: Mon, 5 Feb 2001 00:27:35 +0000 Subject: fix nested extern --- boggle/boggle/help.c | 6 +++--- boggle/boggle/mach.c | 15 ++++++--------- boggle/boggle/timer.c | 11 ++++++----- boggle/boggle/word.c | 9 +++++---- 4 files changed, 20 insertions(+), 21 deletions(-) (limited to 'boggle') diff --git a/boggle/boggle/help.c b/boggle/boggle/help.c index 8e64afaa..fad25088 100644 --- a/boggle/boggle/help.c +++ b/boggle/boggle/help.c @@ -1,4 +1,4 @@ -/* $NetBSD: help.c,v 1.3 1997/10/10 12:04:26 lukem Exp $ */ +/* $NetBSD: help.c,v 1.4 2001/02/05 00:27:35 christos Exp $ */ /*- * Copyright (c) 1993 @@ -41,7 +41,7 @@ #if 0 static char sccsid[] = "@(#)help.c 8.1 (Berkeley) 6/11/93"; #else -__RCSID("$NetBSD: help.c,v 1.3 1997/10/10 12:04:26 lukem Exp $"); +__RCSID("$NetBSD: help.c,v 1.4 2001/02/05 00:27:35 christos Exp $"); #endif #endif /* not lint */ @@ -51,10 +51,10 @@ __RCSID("$NetBSD: help.c,v 1.3 1997/10/10 12:04:26 lukem Exp $"); #include "bog.h" #include "extern.h" +extern int nlines; int help() { - extern int nlines; int eof, i; FILE *fp; WINDOW *win; diff --git a/boggle/boggle/mach.c b/boggle/boggle/mach.c index 6aacf1cd..92ccc37e 100644 --- a/boggle/boggle/mach.c +++ b/boggle/boggle/mach.c @@ -1,4 +1,4 @@ -/* $NetBSD: mach.c,v 1.10 1999/09/08 21:45:26 jsm Exp $ */ +/* $NetBSD: mach.c,v 1.11 2001/02/05 00:27:35 christos Exp $ */ /*- * Copyright (c) 1993 @@ -41,7 +41,7 @@ #if 0 static char sccsid[] = "@(#)mach.c 8.1 (Berkeley) 6/11/93"; #else -__RCSID("$NetBSD: mach.c,v 1.10 1999/09/08 21:45:26 jsm Exp $"); +__RCSID("$NetBSD: mach.c,v 1.11 2001/02/05 00:27:35 christos Exp $"); #endif #endif /* not lint */ @@ -72,6 +72,10 @@ int ncols, nlines; extern const char *pword[], *mword[]; extern int ngames, nmwords, npwords, tnmwords, tnpwords; +extern char board[]; +extern int usedbits, wordpath[]; +extern time_t start_t; +extern int debug; static void cont_catcher __P((int)); static int prwidth __P((const char *const [], int)); @@ -91,8 +95,6 @@ setup(sflag, seed) int sflag; time_t seed; { - extern int debug; - if (tty_setup() < 0) return(-1); @@ -293,7 +295,6 @@ static int gone; void stoptime() { - extern time_t start_t; time_t t; (void)time(&t); @@ -306,7 +307,6 @@ stoptime() void starttime() { - extern time_t start_t; time_t t; (void)time(&t); @@ -408,9 +408,6 @@ findword() { int c, col, found, i, r, row; char buf[MAXWORDLEN + 1]; - extern char board[]; - extern int usedbits, wordpath[]; - extern int nmwords, npwords; getyx(stdscr, r, c); getword(buf); diff --git a/boggle/boggle/timer.c b/boggle/boggle/timer.c index dcf3fb1f..5ac733b0 100644 --- a/boggle/boggle/timer.c +++ b/boggle/boggle/timer.c @@ -1,4 +1,4 @@ -/* $NetBSD: timer.c,v 1.4 1997/10/10 12:04:36 lukem Exp $ */ +/* $NetBSD: timer.c,v 1.5 2001/02/05 00:27:35 christos Exp $ */ /*- * Copyright (c) 1993 @@ -41,7 +41,7 @@ #if 0 static char sccsid[] = "@(#)timer.c 8.2 (Berkeley) 2/22/94"; #else -__RCSID("$NetBSD: timer.c,v 1.4 1997/10/10 12:04:36 lukem Exp $"); +__RCSID("$NetBSD: timer.c,v 1.5 2001/02/05 00:27:35 christos Exp $"); #endif #endif /* not lint */ @@ -59,6 +59,10 @@ __RCSID("$NetBSD: timer.c,v 1.4 1997/10/10 12:04:36 lukem Exp $"); static int waitch __P((long)); +extern int tlimit; +extern time_t start_t; +extern jmp_buf env; + /* * Update the display of the remaining time while waiting for a character * If time runs out do a longjmp() to the game controlling routine, returning @@ -68,9 +72,6 @@ static int waitch __P((long)); int timerch() { - extern int tlimit; - extern time_t start_t; - extern jmp_buf env; time_t prevt, t; int col, remaining, row; diff --git a/boggle/boggle/word.c b/boggle/boggle/word.c index b91f3a7b..ec112843 100644 --- a/boggle/boggle/word.c +++ b/boggle/boggle/word.c @@ -1,4 +1,4 @@ -/* $NetBSD: word.c,v 1.5 1999/09/08 21:17:45 jsm Exp $ */ +/* $NetBSD: word.c,v 1.6 2001/02/05 00:27:35 christos Exp $ */ /*- * Copyright (c) 1993 @@ -41,7 +41,7 @@ #if 0 static char sccsid[] = "@(#)word.c 8.1 (Berkeley) 6/11/93"; #else -__RCSID("$NetBSD: word.c,v 1.5 1999/09/08 21:17:45 jsm Exp $"); +__RCSID("$NetBSD: word.c,v 1.6 2001/02/05 00:27:35 christos Exp $"); #endif #endif /* not lint */ @@ -61,6 +61,9 @@ static char *sp; static int first = 1, lastch = 0; +extern struct dictindex dictindex[]; +extern int wordlen; + /* * Return the next word in the compressed dictionary in 'buffer' or * NULL on end-of-file @@ -69,7 +72,6 @@ char * nextword(fp) FILE *fp; { - extern int wordlen; int ch, pcount; char *p; static char buf[MAXWORDLEN + 1]; @@ -193,7 +195,6 @@ loadindex(indexfile) int i, j; char buf[BUFSIZ]; FILE *fp; - extern struct dictindex dictindex[]; if ((fp = fopen(indexfile, "r")) == NULL) { warn("Can't open '%s'", indexfile); -- cgit v1.2.3-56-ge451