summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBardur Arantsson <bardur@scientician.net>2016-03-27 15:46:59 +0200
committerBardur Arantsson <bardur@scientician.net>2016-03-27 15:47:19 +0200
commitc999ae0630fbdc08b3e95f4d9987a69315f9713b (patch)
treeca22eaf61330be51db477922f6153fd0919b83a4
parent5adeda8d795191c8d8741795f1961cbe070828cb (diff)
Tidy up variable initialization in object_desc_aux
-rw-r--r--src/object1.cc8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/object1.cc b/src/object1.cc
index cb935973..78206f68 100644
--- a/src/object1.cc
+++ b/src/object1.cc
@@ -1129,9 +1129,6 @@ std::string object_desc_aux(object_type *o_ptr, int pref, int mode)
{
bool_ hack_name = FALSE;
- bool_ aware = FALSE;
- bool_ known = FALSE;
-
bool_ append_name = FALSE;
bool_ show_weapon = FALSE;
@@ -1143,12 +1140,11 @@ std::string object_desc_aux(object_type *o_ptr, int pref, int mode)
u32b f1, f2, f3, f4, f5, esp;
object_flags(o_ptr, &f1, &f2, &f3, &f4, &f5, &esp);
-
/* See if the object is "aware" */
- if (object_aware_p(o_ptr)) aware = TRUE;
+ bool_ aware = object_aware_p(o_ptr);
/* See if the object is "known" */
- if (object_known_p(o_ptr)) known = TRUE;
+ bool_ known = object_known_p(o_ptr);
/* Hack -- Extract the sub-type "indexx" */
auto const indexx = o_ptr->sval;