summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/externs.h4
-rw-r--r--src/variable.cc13
-rw-r--r--src/xtra2.cc16
3 files changed, 14 insertions, 19 deletions
diff --git a/src/externs.h b/src/externs.h
index d29fefa1..430cef2b 100644
--- a/src/externs.h
+++ b/src/externs.h
@@ -436,8 +436,6 @@ extern char pref_tmp_value[8];
extern bool_ item_tester_full;
extern byte item_tester_tval;
extern bool_ (*item_tester_hook)(object_type *o_ptr);
-extern bool_ (*ang_sort_comp)(vptr u, vptr v, int a, int b);
-extern void (*ang_sort_swap)(vptr u, vptr v, int a, int b);
extern bool_ (*get_mon_num_hook)(int r_idx);
extern bool_ (*get_mon_num2_hook)(int r_idx);
extern bool_ (*get_obj_num_hook)(int k_idx);
@@ -2105,8 +2103,6 @@ extern void verify_panel(void);
extern void resize_map(void);
extern void resize_window(void);
extern cptr look_mon_desc(int m_idx);
-extern void ang_sort_aux(vptr u, vptr v, int p, int q);
-extern void ang_sort(vptr u, vptr v, int n);
extern bool_ target_able(int m_idx);
extern bool_ target_okay(void);
extern bool_ target_set(int mode);
diff --git a/src/variable.cc b/src/variable.cc
index 16eda4dc..bf27393b 100644
--- a/src/variable.cc
+++ b/src/variable.cc
@@ -977,19 +977,6 @@ bool_ (*item_tester_hook)(object_type*);
/*
- * Current "comp" function for ang_sort()
- */
-bool_ (*ang_sort_comp)(vptr u, vptr v, int a, int b);
-
-
-/*
- * Current "swap" function for ang_sort()
- */
-void (*ang_sort_swap)(vptr u, vptr v, int a, int b);
-
-
-
-/*
* Hack -- function hooks to restrict "get_mon_num_prep()" function
*/
bool_ (*get_mon_num_hook)(int r_idx);
diff --git a/src/xtra2.cc b/src/xtra2.cc
index 397ca133..d1d3e4ac 100644
--- a/src/xtra2.cc
+++ b/src/xtra2.cc
@@ -3841,6 +3841,18 @@ cptr look_mon_desc(int m_idx)
/*
+ * Current "comp" function for ang_sort()
+ */
+static bool_ (*ang_sort_comp)(vptr u, vptr v, int a, int b) = nullptr;
+
+/*
+ * Current "swap" function for ang_sort()
+ */
+static void (*ang_sort_swap)(vptr u, vptr v, int a, int b) = nullptr;
+
+
+
+/*
* Angband sorting algorithm -- quick sort in place
*
* Note that the details of the data we are sorting is hidden,
@@ -3848,7 +3860,7 @@ cptr look_mon_desc(int m_idx)
* function hooks to interact with the data, which is given as
* two pointers, and which may have any user-defined form.
*/
-void ang_sort_aux(vptr u, vptr v, int p, int q)
+static void ang_sort_aux(vptr u, vptr v, int p, int q)
{
int z, a, b;
@@ -3897,7 +3909,7 @@ void ang_sort_aux(vptr u, vptr v, int p, int q)
* function hooks to interact with the data, which is given as
* two pointers, and which may have any user-defined form.
*/
-void ang_sort(vptr u, vptr v, int n)
+static void ang_sort(vptr u, vptr v, int n)
{
/* Sort the array */
ang_sort_aux(u, v, 0, n - 1);