gbranden pushed a commit to branch master
in repository groff.

commit 41c6cf61c28f3d13502e91a6d41d4b2152e2117e
Author: G. Branden Robinson <[email protected]>
AuthorDate: Thu Jun 11 15:45:28 2026 -0500

    [soelim]: Declare file-local functions as static.
    
    * src/preproc/soelim/soelim.cpp (usage, set_location, do_so): Define
      function as `static`; external linkage is not required.
    
    Fixes `-Wmissing-declarations` GCC warning.
---
 ChangeLog                     | 7 +++++++
 src/preproc/soelim/soelim.cpp | 6 +++---
 2 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 56cc7684b..69bfb2c12 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2026-06-11  G. Branden Robinson <[email protected]>
+
+       * src/preproc/soelim/soelim.cpp (usage, set_location, do_so):
+       Define function as `static`; external linkage is not required.
+
+       Fixes `-Wmissing-declarations` GCC warning.
+
 2026-06-11  G. Branden Robinson <[email protected]>
 
        * src/preproc/refer/command.cpp (get_word):
diff --git a/src/preproc/soelim/soelim.cpp b/src/preproc/soelim/soelim.cpp
index e49c879a1..1064edaef 100644
--- a/src/preproc/soelim/soelim.cpp
+++ b/src/preproc/soelim/soelim.cpp
@@ -49,7 +49,7 @@ extern "C" const char *Version_string;
 // forward declaration
 static bool do_file(const char *);
 
-void usage(FILE *stream)
+static void usage(FILE *stream)
 {
   fprintf(stream, "usage: %s [-Crt] [-I dir] [input-file ...]\n"
          "usage: %s {-v | --version}\n"
@@ -132,7 +132,7 @@ int main(int argc, char **argv)
   return (nbad != 0);
 }
 
-void set_location()
+static void set_location()
 {
   if (!want_raw_output) {
     if (!want_tex_output)
@@ -144,7 +144,7 @@ void set_location()
   }
 }
 
-void do_so(const char *line)
+static void do_so(const char *line)
 {
   const char *p = line;
   while (*p == ' ')

_______________________________________________
groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit

Reply via email to