remove register from variable declarations
This commit is contained in:
48
src/detect.c
48
src/detect.c
@@ -185,7 +185,7 @@ trapped_door_at(int ttyp, coordxy x, coordxy y)
|
||||
struct obj *
|
||||
o_in(struct obj *obj, char oclass)
|
||||
{
|
||||
register struct obj *otmp;
|
||||
struct obj *otmp;
|
||||
struct obj *temp;
|
||||
|
||||
if (obj->oclass == oclass)
|
||||
@@ -213,7 +213,7 @@ o_in(struct obj *obj, char oclass)
|
||||
struct obj *
|
||||
o_material(struct obj *obj, unsigned material)
|
||||
{
|
||||
register struct obj *otmp;
|
||||
struct obj *otmp;
|
||||
struct obj *temp;
|
||||
|
||||
if (objects[obj->otyp].oc_material == material)
|
||||
@@ -247,8 +247,8 @@ static boolean
|
||||
check_map_spot(coordxy x, coordxy y, char oclass, unsigned material)
|
||||
{
|
||||
int glyph;
|
||||
register struct obj *otmp;
|
||||
register struct monst *mtmp;
|
||||
struct obj *otmp;
|
||||
struct monst *mtmp;
|
||||
|
||||
glyph = glyph_at(x, y);
|
||||
if (glyph_is_object(glyph)) {
|
||||
@@ -300,7 +300,7 @@ check_map_spot(coordxy x, coordxy y, char oclass, unsigned material)
|
||||
static boolean
|
||||
clear_stale_map(char oclass, unsigned material)
|
||||
{
|
||||
register coordxy zx, zy;
|
||||
coordxy zx, zy;
|
||||
boolean change_made = FALSE;
|
||||
|
||||
for (zx = 1; zx < COLNO; zx++)
|
||||
@@ -317,8 +317,8 @@ clear_stale_map(char oclass, unsigned material)
|
||||
int
|
||||
gold_detect(struct obj *sobj)
|
||||
{
|
||||
register struct obj *obj;
|
||||
register struct monst *mtmp;
|
||||
struct obj *obj;
|
||||
struct monst *mtmp;
|
||||
struct obj gold, *temp = 0;
|
||||
boolean stale, ugold = FALSE, steedgold = FALSE;
|
||||
int ter_typ = TER_DETECT | TER_OBJ;
|
||||
@@ -461,9 +461,9 @@ gold_detect(struct obj *sobj)
|
||||
int
|
||||
food_detect(struct obj *sobj)
|
||||
{
|
||||
register struct obj *obj;
|
||||
register struct monst *mtmp;
|
||||
register int ct = 0, ctu = 0;
|
||||
struct obj *obj;
|
||||
struct monst *mtmp;
|
||||
int ct = 0, ctu = 0;
|
||||
boolean confused = (Confusion || (sobj && sobj->cursed)), stale;
|
||||
char oclass = confused ? POTION_CLASS : FOOD_CLASS;
|
||||
const char *what = confused ? something : "food";
|
||||
@@ -586,15 +586,15 @@ int
|
||||
object_detect(struct obj *detector, /* object doing the detecting */
|
||||
int class) /* an object class, 0 for all */
|
||||
{
|
||||
register coordxy x, y;
|
||||
coordxy x, y;
|
||||
char stuff[BUFSZ];
|
||||
int is_cursed = (detector && detector->cursed);
|
||||
int do_dknown = (detector && (detector->oclass == POTION_CLASS
|
||||
|| detector->oclass == SPBOOK_CLASS)
|
||||
&& detector->blessed);
|
||||
int ct = 0, ctu = 0;
|
||||
register struct obj *obj, *otmp = (struct obj *) 0;
|
||||
register struct monst *mtmp;
|
||||
struct obj *obj, *otmp = (struct obj *) 0;
|
||||
struct monst *mtmp;
|
||||
int sym, boulder = 0, ter_typ = TER_DETECT | TER_OBJ;
|
||||
|
||||
if (class < 0 || class >= MAXOCLASSES) {
|
||||
@@ -781,7 +781,7 @@ int
|
||||
monster_detect(struct obj *otmp, /* detecting object (if any) */
|
||||
int mclass) /* monster class, 0 for all */
|
||||
{
|
||||
register struct monst *mtmp;
|
||||
struct monst *mtmp;
|
||||
int mcnt = 0;
|
||||
|
||||
/* Note: This used to just check fmon for a non-zero value
|
||||
@@ -976,7 +976,7 @@ int
|
||||
trap_detect(
|
||||
struct obj *sobj) /* Null if crystal ball, scroll if gold detection */
|
||||
{
|
||||
register struct trap *ttmp;
|
||||
struct trap *ttmp;
|
||||
struct monst *mon;
|
||||
int door, tr;
|
||||
int cursed_src = sobj && sobj->cursed;
|
||||
@@ -1381,7 +1381,7 @@ show_map_spot(coordxy x, coordxy y, boolean cnf)
|
||||
void
|
||||
do_mapping(void)
|
||||
{
|
||||
register int zx, zy;
|
||||
int zx, zy;
|
||||
boolean unconstrained;
|
||||
|
||||
unconstrained = unconstrain_map();
|
||||
@@ -1407,7 +1407,7 @@ do_mapping(void)
|
||||
void
|
||||
do_vicinity_map(struct obj *sobj) /* scroll--actually fake spellbook--object */
|
||||
{
|
||||
register int zx, zy;
|
||||
int zx, zy;
|
||||
struct monst *mtmp;
|
||||
struct obj *otmp;
|
||||
long save_EDetect_mons;
|
||||
@@ -1627,8 +1627,8 @@ findone(coordxy zx, coordxy zy, genericptr_t whatfound)
|
||||
static void
|
||||
openone(coordxy zx, coordxy zy, genericptr_t num)
|
||||
{
|
||||
register struct trap *ttmp;
|
||||
register struct obj *otmp;
|
||||
struct trap *ttmp;
|
||||
struct obj *otmp;
|
||||
int *num_p = (int *) num;
|
||||
|
||||
if (OBJ_AT(zx, zy)) {
|
||||
@@ -1886,8 +1886,8 @@ int
|
||||
dosearch0(int aflag) /* intrinsic autosearch vs explicit searching */
|
||||
{
|
||||
coordxy x, y;
|
||||
register struct trap *trap;
|
||||
register struct monst *mtmp;
|
||||
struct trap *trap;
|
||||
struct monst *mtmp;
|
||||
|
||||
if (u.uswallow) {
|
||||
if (!aflag)
|
||||
@@ -1992,9 +1992,9 @@ warnreveal(void)
|
||||
void
|
||||
premap_detect(void)
|
||||
{
|
||||
register coordxy x, y;
|
||||
register struct trap *ttmp;
|
||||
register struct obj *obj;
|
||||
coordxy x, y;
|
||||
struct trap *ttmp;
|
||||
struct obj *obj;
|
||||
|
||||
/* Map the background and boulders */
|
||||
for (x = 1; x < COLNO; x++)
|
||||
|
||||
Reference in New Issue
Block a user