From 0a2dc67e75699879d5a0b0bcb39205a60ee2889b Mon Sep 17 00:00:00 2001 From: nhmall Date: Sun, 19 Sep 2021 15:15:11 -0400 Subject: [PATCH] build warning MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit sp_lev.c: In function ‘lspo_altar’: sp_lev.c:3962:9: warning: declaration of ‘shrine’ shadows a global declaration [-Wshadow] 3962 | int shrine; | ^~~~~~ In file included from ../include/hack.h:217, from sp_lev.c:14: ../include/display.h:959:5: note: shadowed declaration is here 959 | shrine | ^~~~~~ --- include/display.h | 2 +- win/share/tilemap.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/include/display.h b/include/display.h index 30a681351..2081f0b32 100644 --- a/include/display.h +++ b/include/display.h @@ -956,7 +956,7 @@ enum altar_types { altar_chaotic, altar_neutral, altar_lawful, - shrine + altar_shrine }; enum { GM_FLAGS, GM_TTYCHAR, GM_COLOR, NUM_GLYPHMOD }; /* glyphmod entries */ diff --git a/win/share/tilemap.c b/win/share/tilemap.c index 29ab8ed88..52bc1d74e 100644 --- a/win/share/tilemap.c +++ b/win/share/tilemap.c @@ -329,7 +329,7 @@ tilename(int set, const int file_entry, int gend UNUSED) /* Altars */ cmap = S_altar; - for (k = altar_unaligned; k <= shrine; k++) { + for (k = altar_unaligned; k <= altar_shrine; k++) { /* Since defsyms only has one altar symbol, it isn't much help in identifying details these. Roll our own name. */ @@ -889,7 +889,7 @@ init_tilemap(void) /* Altars */ cmap = S_altar; j = 0; - for (k = altar_unaligned; k <= shrine; k++) { + for (k = altar_unaligned; k <= altar_shrine; k++) { offset = GLYPH_ALTAR_OFF + j; precheck((offset), "altar"); tilemap[offset].tilenum = tilenum;