comparison xrogue/rogue.h @ 236:7c1cb43f346e

XRogue: get rid of VOID as an alias for long. Maybe some compilers in 1986 didn't handle void pointers well, but they are no longer a concern.
author John "Elwin" Edwards
date Mon, 07 Mar 2016 20:44:01 -0500
parents b67b99f6c92b
children e1cd27c5464f
comparison
equal deleted inserted replaced
235:2dcf10d45d5b 236:7c1cb43f346e
18 18
19 #ifdef HAVE_CONFIG_H 19 #ifdef HAVE_CONFIG_H
20 #include "config.h" 20 #include "config.h"
21 #endif 21 #endif
22 22
23 /*
24 * some compiler don't handle void pointers well so
25 */
26 #include <assert.h> 23 #include <assert.h>
27 #define reg register 24 #define reg register
28 #define VOID long
29 #undef lines 25 #undef lines
30 #define ENCREAD encread 26 #define ENCREAD encread
31 #define ENCWRITE encwrite 27 #define ENCWRITE encwrite
32 #undef SCROLL /* UNIX/370 defines SCROLL for some bizarre reason */ 28 #undef SCROLL /* UNIX/370 defines SCROLL for some bizarre reason */
33 #define exfork fork /* Standard fork with no paging available */ 29 #define exfork fork /* Standard fork with no paging available */
933 929
934 struct delayed_action { 930 struct delayed_action {
935 int d_type; 931 int d_type;
936 void (*d_func)(); 932 void (*d_func)();
937 union { 933 union {
938 VOID *vp; 934 void *vp;
939 int i; 935 int i;
940 } d_arg; 936 } d_arg;
941 int d_time; 937 int d_time;
942 }; 938 };
943 939
1320 struct delayed_action *find_slot(void (*func)()); 1316 struct delayed_action *find_slot(void (*func)());
1321 int findmindex(char *name); 1317 int findmindex(char *name);
1322 void fix_stick(struct object *cur); 1318 void fix_stick(struct object *cur);
1323 void fright(struct thing *th); 1319 void fright(struct thing *th);
1324 void fumble(void); 1320 void fumble(void);
1325 void fuse(void (*dfunc)(), VOID *arg, int time, int type); 1321 void fuse(void (*dfunc)(), void *arg, int time, int type);
1326 void genmonsters(int least, bool treas); 1322 void genmonsters(int least, bool treas);
1327 coord get_coordinates(void); 1323 coord get_coordinates(void);
1328 bool get_dir(coord *direction); 1324 bool get_dir(coord *direction);
1329 struct linked_list *get_hurl(struct thing *tp); 1325 struct linked_list *get_hurl(struct thing *tp);
1330 struct linked_list *get_item(struct linked_list *list, char *purpose, int type, 1326 struct linked_list *get_item(struct linked_list *list, char *purpose, int type,
1450 void sight(void); 1446 void sight(void);
1451 bool skirmish(struct thing *attacker, coord *mp, struct object *weap, 1447 bool skirmish(struct thing *attacker, coord *mp, struct object *weap,
1452 bool thrown); 1448 bool thrown);
1453 struct linked_list *spec_item(int type, int which, int hit, int damage); 1449 struct linked_list *spec_item(int type, int which, int hit, int damage);
1454 void spell_recovery(void); 1450 void spell_recovery(void);
1455 void start_daemon(void (*dfunc)(), VOID *arg, int type); 1451 void start_daemon(void (*dfunc)(), void *arg, int type);
1456 void status(bool display); 1452 void status(bool display);
1457 void steal(void); 1453 void steal(void);
1458 bool step_ok(int y, int x, int can_on_monst, struct thing *flgptr); 1454 bool step_ok(int y, int x, int can_on_monst, struct thing *flgptr);
1459 void stomach(void); 1455 void stomach(void);
1460 int str_compute(void); 1456 int str_compute(void);