groff-commit
[Top][All Lists]
Advanced

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

[groff] 37/60: src/roff/troff/input.cpp: Fix source style nits.


From: G. Branden Robinson
Subject: [groff] 37/60: src/roff/troff/input.cpp: Fix source style nits.
Date: Wed, 11 Sep 2024 03:38:32 -0400 (EDT)

gbranden pushed a commit to branch master
in repository groff.

commit 9cafce4641f4b39b0fd7075b6b5f299984edd09a
Author: G. Branden Robinson <g.branden.robinson@gmail.com>
AuthorDate: Mon Sep 9 23:06:16 2024 -0500

    src/roff/troff/input.cpp: Fix source style nits.
    
    * Annotate null pointers with `nullptr` comment to ease any future
      transition to C++11, which defines it as a keyword.
---
 src/roff/troff/input.cpp | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/roff/troff/input.cpp b/src/roff/troff/input.cpp
index 032f5c9b2..c6719281a 100644
--- a/src/roff/troff/input.cpp
+++ b/src/roff/troff/input.cpp
@@ -2981,7 +2981,7 @@ static int transparent_translate(int cc)
 
 int node::reread(int *)
 {
-  return 0;
+  return 0 /* nullptr */;
 }
 
 int global_diverted_space = 0;
@@ -4564,7 +4564,7 @@ static void remove_character()
       charinfo *ci = tok.get_char(true /* required */);
       if (!ci)
        break;
-      macro *m = ci->set_macro(0);
+      macro *m = ci->set_macro(0 /* nullptr */);
       if (m)
        delete m;
     }
@@ -9108,8 +9108,8 @@ node *charinfo_to_node_list(charinfo *ci, const 
environment *envp)
   want_att_compat = false;
   int previous_escape_char = escape_char;
   escape_char = '\\';
-  macro *mac = ci->set_macro(0);
-  assert(mac != 0);
+  macro *mac = ci->set_macro(0 /* nullptr */);
+  assert(mac != 0 /* nullptr */);
   environment *oldenv = curenv;
   environment env(envp);
   curenv = &env;



reply via email to

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