groff-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[groff] 01/26: src/libs/libgroff/filename.cpp: Update comments.


From: G. Branden Robinson
Subject: [groff] 01/26: src/libs/libgroff/filename.cpp: Update comments.
Date: Sun, 15 May 2022 05:07:51 -0400 (EDT)

gbranden pushed a commit to branch master
in repository groff.

commit 9deb4d1834fa5f73865627ceb1e90b1c267f2140
Author: G. Branden Robinson <g.branden.robinson@gmail.com>
AuthorDate: Wed May 4 18:15:10 2022 -0500

    src/libs/libgroff/filename.cpp: Update comments.
    
    * Explain purposes of and distinction between `current_filename` and
      `current_source_filename`.
    * Annotate use of zero literals as null pointers to ease any future
      migration to ISO C++11.
    * Update license notice from GPLv2 to GPLv3 (seemingly overlooked
      earlier).
    * Update editor aid comments; drop old-style Emacs file-local variable
      setting.
---
 src/libs/libgroff/filename.cpp | 24 ++++++++++++++++++------
 1 file changed, 18 insertions(+), 6 deletions(-)

diff --git a/src/libs/libgroff/filename.cpp b/src/libs/libgroff/filename.cpp
index 5716a4a7..ded9738e 100644
--- a/src/libs/libgroff/filename.cpp
+++ b/src/libs/libgroff/filename.cpp
@@ -1,10 +1,10 @@
-/* Copyright (C) 2014-2020 Free Software Foundation, Inc.
+/* Copyright (C) 2014-2022 Free Software Foundation, Inc.
 
 This file is part of groff.
 
 groff is free software; you can redistribute it and/or modify it under
 the terms of the GNU General Public License as published by the Free
-Software Foundation, either version 2 of the License, or
+Software Foundation, either version 3 of the License, or
 (at your option) any later version.
 
 groff is distributed in the hope that it will be useful, but WITHOUT ANY
@@ -12,8 +12,20 @@ WARRANTY; without even the implied warranty of 
MERCHANTABILITY or
 FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 for more details.
 
-The GNU General Public License version 2 (GPL2) is available in the
-internet at <http://www.gnu.org/licenses/gpl-2.0.txt>. */
+You should have received a copy of the GNU General Public License
+along with this program.  If not, see <http://www.gnu.org/licenses/>. */
 
-const char *current_filename = 0;
-const char *current_source_filename = 0;
+// This global stores the name of the input file being processed by
+// troff, an output driver, or other program.
+const char *current_filename = 0 /* nullptr */;
+
+// This global stores the name of the troff input file corresponding to
+// the part of a device-independent troff output being processed; it is
+// used only by output drivers.
+const char *current_source_filename = 0 /* nullptr */;
+
+// Local Variables:
+// fill-column: 72
+// mode: C++
+// End:
+// vim: set cindent noexpandtab shiftwidth=2 textwidth=72:



reply via email to

[Prev in Thread] Current Thread [Next in Thread]