diff options
author | hubertf <hubertf@NetBSD.org> | 1999-02-10 12:29:47 +0000 |
---|---|---|
committer | hubertf <hubertf@NetBSD.org> | 1999-02-10 12:29:47 +0000 |
commit | f2e552ba9ea473d3399e7b124077a7e4a856138b (patch) | |
tree | ce3f13ceac941baa50c07a090d8cbd73be7fda90 /backgammon/teachgammon/tutor.h | |
parent | 19bd733c3aad11dcfb4bbcf06abf79ff64442032 (diff) | |
download | bsdgames-darwin-f2e552ba9ea473d3399e7b124077a7e4a856138b.tar.gz bsdgames-darwin-f2e552ba9ea473d3399e7b124077a7e4a856138b.tar.zst bsdgames-darwin-f2e552ba9ea473d3399e7b124077a7e4a856138b.zip |
The patch below makes the game backgammon(6) use `const' where
appropriate. It also removes some obsolete, unused code to check the
number of users on the system (obsoleted by dm); removes a prototype
for an unused function that was removed earlier; and removes a control
character from one message that was I think intended to clear the
screen on some particular terminal (though I can't find the comment to
that effect in any of the BSD source trees I have handy) but no longer
serves any useful purpose.
From PR 6580 by Joseph Myers <jsm28@cam.ac.uk>.
Also contains two more patches, one in teachgammon/tutor.h (by Joseph)
and one in common_source/fancy.c (by me).
Diffstat (limited to 'backgammon/teachgammon/tutor.h')
-rw-r--r-- | backgammon/teachgammon/tutor.h | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/backgammon/teachgammon/tutor.h b/backgammon/teachgammon/tutor.h index b709d075..e3ba2f7e 100644 --- a/backgammon/teachgammon/tutor.h +++ b/backgammon/teachgammon/tutor.h @@ -1,4 +1,4 @@ -/* $NetBSD: tutor.h,v 1.5 1998/09/13 15:27:26 hubertf Exp $ */ +/* $NetBSD: tutor.h,v 1.6 1999/02/10 12:29:48 hubertf Exp $ */ /* * Copyright (c) 1980, 1993 @@ -43,30 +43,30 @@ struct situatn { int mg[4]; int new1; int new2; - char *(*com[8]); + const char *const (*com[8]); }; -extern char *doubl[]; -extern char *endgame[]; -extern char *finis[]; -extern char *hello[]; -extern char *hits[]; -extern char *intro1[]; -extern char *intro2[]; -extern char *lastch[]; -extern char *list[]; +extern const char *const doubl[]; +extern const char *const endgame[]; +extern const char *const finis[]; +extern const char *const hello[]; +extern const char *const hits[]; +extern const char *const intro1[]; +extern const char *const intro2[]; +extern const char *const lastch[]; +extern const char *const list[]; extern int maxmoves; -extern char *moves[]; -extern char *opts; -extern char *prog[]; -extern char *prompt; -extern char *removepiece[]; -extern char *stragy[]; -extern struct situatn test[]; +extern const char *const moves[]; +extern const char *const opts; +extern const char *const prog[]; +extern const char *const prompt; +extern const char *const removepiece[]; +extern const char *const stragy[]; +extern const struct situatn test[]; -int brdeq __P((int *, int *)); +int brdeq __P((const int *, const int *)); void clrest __P((void)); void leave __P((void)) __attribute__((__noreturn__)); void tutor __P((void)) __attribute__((__noreturn__)); |