This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[commit/Ada] Make ada-tasks.c:ada_task_is_alive static


One tiny little code cleanup...

2009-03-12  Joel Brobecker  <brobecker@adacore.com>

        * ada-tasks.c (ada_task_is_alive): Move up and make static.
        * ada-lang.h (ada_task_is_alive): Remove declaration.


Tested on amd64-linux. Checked in.

-- 
Joel
diff --git a/gdb/ada-lang.h b/gdb/ada-lang.h
index 946ffcc..50f90fb 100644
--- a/gdb/ada-lang.h
+++ b/gdb/ada-lang.h
@@ -226,8 +226,6 @@ struct ada_task_info
   CORE_ADDR caller_task;
 };
 
-int ada_task_is_alive (struct ada_task_info *task);
-
 /* Assuming V points to an array of S objects,  make sure that it contains at
    least M objects, updating V and S as necessary. */
 
diff --git a/gdb/ada-tasks.c b/gdb/ada-tasks.c
index 599a17b..d0ce5ab 100644
--- a/gdb/ada-tasks.c
+++ b/gdb/ada-tasks.c
@@ -202,6 +202,15 @@ valid_task_id (int task_num)
           && task_num <= VEC_length (ada_task_info_s, task_list));
 }
 
+/* Return non-zero iff the task STATE corresponds to a non-terminated
+   task state.  */
+
+static int
+ada_task_is_alive (struct ada_task_info *task_info)
+{
+  return (task_info->state != Terminated);
+}
+
 /* Extract the contents of the value as a string whose length is LENGTH,
    and store the result in DEST.  */
 
@@ -662,15 +671,6 @@ ada_build_task_list (int warn_if_null)
   return 1;
 }
 
-/* Return non-zero iff the task STATE corresponds to a non-terminated
-   task state.  */
-
-int
-ada_task_is_alive (struct ada_task_info *task_info)
-{
-  return (task_info->state != Terminated);
-}
-
 /* Print a one-line description of the task whose number is TASKNO.
    The formatting should fit the "info tasks" array.  */
 

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]