gbranden pushed a commit to branch master
in repository groff.
commit 023083d16d54b6de2bf66dcd6bc36b39698a5a46
Author: G. Branden Robinson <[email protected]>
AuthorDate: Sat Apr 27 00:56:54 2024 -0500
[troff]: Boolify env.cpp (13/25).
[troff]: Boolify more `environment` class member variables, member
function parameters, and local variables.
* src/roff/troff/env.h (class environment):
* src/roff/troff/env.cpp (environment::handle_tab): Demote parameter
`is_leader` from `int` to `bool`. Assign Boolean literal to it.
---
ChangeLog | 5 +++++
src/roff/troff/env.cpp | 2 +-
src/roff/troff/env.h | 2 +-
3 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index c31e7db71..36f39e873 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -98,6 +98,11 @@
Rename parameter `forced` to `must_adjust` and demote it from
`int` to `bool`.
+ * src/roff/troff/env.h (class environment):
+ * src/roff/troff/env.cpp (environment::handle_tab): Demote
+ parameter `is_leader` from `int` to `bool`. Assign Boolean
+ literal to it.
+
2024-04-24 G. Branden Robinson <[email protected]>
* src/roff/troff/env.cpp (tab_stops::to_string)
diff --git a/src/roff/troff/env.cpp b/src/roff/troff/env.cpp
index 436c70fcd..e592fcbda 100644
--- a/src/roff/troff/env.cpp
+++ b/src/roff/troff/env.cpp
@@ -3013,7 +3013,7 @@ node *environment::make_tab_node(hunits d, node *next)
return n;
}
-void environment::handle_tab(int is_leader)
+void environment::handle_tab(bool is_leader)
{
hunits d;
hunits absolute;
diff --git a/src/roff/troff/env.h b/src/roff/troff/env.h
index 31b2a8078..99b2dd5cb 100644
--- a/src/roff/troff/env.h
+++ b/src/roff/troff/env.h
@@ -349,7 +349,7 @@ public:
void final_break();
node *make_tag(const char *name, int i);
void newline();
- void handle_tab(int is_leader = 0); // do a tab or leader
+ void handle_tab(bool /* is_leader */ = false); // do a tab or leader
void add_node(node *);
void add_char(charinfo *);
void add_hyphen_indicator();
_______________________________________________
Groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit