diff rogue4/rip.c @ 215:1b73a8641b37

rogue4: fix most GCC5 warnings. Converting all function definitions to ANSI style accounts for most of the change. This has exposed other problems, such as daemons not actually being their stated type, that will require more careful solutions.
author John "Elwin" Edwards
date Wed, 27 Jan 2016 19:41:05 -0500
parents ee250e3646fd
children 23d2e2bf812f
line wrap: on
line diff
--- a/rogue4/rip.c	Sat Jan 23 09:35:14 2016 -0500
+++ b/rogue4/rip.c	Wed Jan 27 19:41:05 2016 -0500
@@ -19,6 +19,8 @@
 #include <stdlib.h>
 #include "rogue.h"
 
+char *killname(char monst, bool doart);
+
 static char *rip[] = {
 "                       __________",
 "                      /          \\",
@@ -41,9 +43,8 @@
  *	Figure score and post it.
  */
 /* VARARGS2 */
-score(amount, flags, monst)
-int amount, flags;
-char monst;
+void
+score(int amount, int flags, char monst)
 {
     register struct sc_ent *scp;
     register int i;
@@ -297,8 +298,8 @@
  * death:
  *	Do something really fun when he dies
  */
-death(monst)
-register char monst;
+void
+death(char monst)
 {
     register char **dp = rip, *killer;
     register struct tm *lt;
@@ -341,7 +342,8 @@
  * total_winner:
  *	Code for a winner
  */
-total_winner()
+void
+total_winner(void)
 {
     register THING *obj;
     register int worth = 0;
@@ -461,9 +463,7 @@
  *	Convert a code to a monster name
  */
 char *
-killname(monst, doart)
-register char monst;
-bool doart;
+killname(char monst, bool doart)
 {
     register const char *sp;
     register bool article;