summaryrefslogtreecommitdiffstats
path: root/mille/mille.h
diff options
context:
space:
mode:
authorjsm <jsm@NetBSD.org>1999-09-08 21:17:44 +0000
committerjsm <jsm@NetBSD.org>1999-09-08 21:17:44 +0000
commit04f4d7044367099914cf1906ae27ac20c24e44cf (patch)
treec17cb5c2f270bbb70eeba18cbe2bcfa43cfd8e10 /mille/mille.h
parentf9706028dd6e2afabb6bd63d02d7bc90f78e4aab (diff)
downloadbsdgames-darwin-04f4d7044367099914cf1906ae27ac20c24e44cf.tar.gz
bsdgames-darwin-04f4d7044367099914cf1906ae27ac20c24e44cf.tar.zst
bsdgames-darwin-04f4d7044367099914cf1906ae27ac20c24e44cf.zip
Add use of `const' where appropriate to the games.
This merges in all such remaining changes from the Linux port of the NetBSD games, except in hunt (where substantial changes from OpenBSD need to be looked at). Some such changes were previously covered in PRs bin/6041, bin/6146, bin/6148, bin/6150, bin/6151, bin/6580, bin/6660, bin/7993, bin/7994, bin/8039, bin/8057 and bin/8093.
Diffstat (limited to 'mille/mille.h')
-rw-r--r--mille/mille.h24
1 files changed, 13 insertions, 11 deletions
diff --git a/mille/mille.h b/mille/mille.h
index 416e9f0d..c110c6b2 100644
--- a/mille/mille.h
+++ b/mille/mille.h
@@ -1,4 +1,4 @@
-/* $NetBSD: mille.h,v 1.9 1998/09/13 15:27:29 hubertf Exp $ */
+/* $NetBSD: mille.h,v 1.10 1999/09/08 21:17:50 jsm Exp $ */
/*
* Copyright (c) 1982, 1993
@@ -207,13 +207,15 @@ typedef struct {
extern bool Debug, Finished, Next, On_exit, Order, Saved;
-extern char *C_fmt, **C_name, *Fromfile, Initstr[];
+extern char Initstr[];
+extern const char *C_fmt, *const *C_name, *Fromfile;
-extern int Card_no, End, Handstart, Movetype, Numcards[], Numgos,
- Numneed[], Numseen[NUM_CARDS], Play, Value[], Window;
+extern int Card_no, End, Handstart, Movetype, Numgos,
+ Numneed[], Numseen[NUM_CARDS], Play, Window;
+extern const int Numcards[], Value[];
-extern CARD Deck[DECK_SZ], Discard, Opposite[NUM_CARDS], Sh_discard,
- *Topcard;
+extern CARD Deck[DECK_SZ], Discard, Sh_discard, *Topcard;
+extern const CARD Opposite[NUM_CARDS];
extern FILE *outf;
@@ -227,7 +229,7 @@ extern WINDOW *Board, *Miles, *Score;
void account __P((CARD));
void calcmove __P((void));
-int canplay __P((PLAY *, PLAY *, CARD));
+int canplay __P((const PLAY *, const PLAY *, CARD));
int check_ext __P((bool));
void check_go __P((void));
void check_more __P((void));
@@ -239,19 +241,19 @@ void finalscore __P((PLAY *));
CARD getcard __P((void));
void getmove __P((void));
int getyn __P((int));
-int haspicked __P((PLAY *));
+int haspicked __P((const PLAY *));
void init __P((void));
int isrepair __P((CARD));
int main __P((int, char **));
void newboard __P((void));
void newscore __P((void));
-int onecard __P((PLAY *));
+int onecard __P((const PLAY *));
int playcard __P((PLAY *));
void prboard __P((void));
void prompt __P((int));
-void prscore __P((int));
+void prscore __P((bool));
int readch __P((void));
-bool rest_f __P((char *));
+bool rest_f __P((const char *));
int roll __P((int, int));
void rub __P((int));
int safety __P((CARD));