From a7d63907a920bb86a1784b3aaa49e631ead8e947 Mon Sep 17 00:00:00 2001
From: "Stephen R. van den Berg" <srb@cuci.nl>
Date: Mon, 10 Jul 2017 14:07:41 +0200
Subject: [PATCH] Rename Debug.Peek to Debug.Inspect.

---
 CHANGES                                            |  4 ++--
 lib/modules/Debug.pmod/{Peek.pike => Inspect.pike} | 14 +++++++-------
 lib/modules/Debug.pmod/module.pmod                 |  2 +-
 3 files changed, 10 insertions(+), 10 deletions(-)
 rename lib/modules/Debug.pmod/{Peek.pike => Inspect.pike} (93%)

diff --git a/CHANGES b/CHANGES
index 59304a3593..19f7e868f3 100644
--- a/CHANGES
+++ b/CHANGES
@@ -91,14 +91,14 @@ o Sql.SQLite
   binary string in a multiset. For example, to store the value "myBinary"
   as a BLOB value using a binding, use: (<"myBinary">).
 
-o Debug.Peek
+o Debug.Inspect
 
   Allows for interactive debugging and live data structure inspection
   in both single- and multi-threaded programs.
 
   Example:
   In the program you'd like to inspect, insert the following one-liner:
-      Debug.Peek("/tmp/test.pike");
+      Debug.Inspect("/tmp/test.pike");
 
   Then start the program and keep it running.
   Next you create a /tmp/test.pike with the following content:
diff --git a/lib/modules/Debug.pmod/Peek.pike b/lib/modules/Debug.pmod/Inspect.pike
similarity index 93%
rename from lib/modules/Debug.pmod/Peek.pike
rename to lib/modules/Debug.pmod/Inspect.pike
index e702fc9f4e..b7119929ae 100644
--- a/lib/modules/Debug.pmod/Peek.pike
+++ b/lib/modules/Debug.pmod/Inspect.pike
@@ -8,7 +8,7 @@
 //! Example:
 //!  In the program you'd like to inspect, insert the following one-liner:
 //! @code
-//!      Debug.Peek("/tmp/test.pike");
+//!      Debug.Inspect("/tmp/test.pike");
 //! @endcode
 //!  Then start the program and keep it running.
 //!  Next you create a /tmp/test.pike with the following content:
@@ -69,14 +69,14 @@ private int lastmtime;
 private int skipnext;
 private int oldsignal;
 
-//! If assigned to, it will allow the diagnostics peek to be triggered
+//! If assigned to, it will allow the diagnostics inspection to be triggered
 //! by this signal.
 int triggersignal;
 
 //! The polling interval in seconds, defaults to 4.
 int pollinterval = POLLINTERVAL;
 
-//! The peek-thread.  It will not appear in the displayed thread-list.
+//! The inspect-thread.  It will not appear in the displayed thread-list.
 Thread.Thread _loopthread;
 
 //! Either the callback function which is invoked on each iteration, or the
@@ -89,18 +89,18 @@ string|function(void:void) _callback;
 
 private void loop(int sig) {
   _loopthread = Thread.this_thread();
-  for(;; peek()) {
+  for(;; inspect()) {
     sleep(pollinterval, 1);
     if (triggersignal != oldsignal) {
-      werror("\nTo peek use: kill -%d %d\n\n",
+      werror("\nTo inspect use: kill -%d %d\n\n",
        triggersignal, getpid());
-      signal(triggersignal, peek);
+      signal(triggersignal, inspect);
     }
   }
 }
 
 //! The internal function which does all the work each pollinterval.
-private void peek() {
+private void inspect() {
   Thread.MutexKey lock;
   if (lock = running->trylock(1)) {
     Thread.Thread thisthread = Thread.this_thread();
diff --git a/lib/modules/Debug.pmod/module.pmod b/lib/modules/Debug.pmod/module.pmod
index edee050b77..98a86c8b45 100644
--- a/lib/modules/Debug.pmod/module.pmod
+++ b/lib/modules/Debug.pmod/module.pmod
@@ -2,7 +2,7 @@
 
 //! Can be custom filled from within your program in order to
 //! have global references to explore live datastructures using
-//! @[Peek]; comes preinitialised with the empty mapping, ready for use.
+//! @[Inspect]; comes preinitialised with the empty mapping, ready for use.
 mapping globals = ([]);
 
 constant verify_internals = _verify_internals;
-- 
GitLab