gbranden pushed a commit to branch master
in repository groff.
commit 0f13fb323a124344893dee5814545d3e3dd7a176
Author: G. Branden Robinson <[email protected]>
AuthorDate: Tue Apr 14 04:03:09 2026 -0500
[troff]: Trivially refactor.
Drop some code introduced in commit dc3c168c3b, 2004-10-10. Per lcov(1)
it's never used, and deleting it does not adversely affect "make check".
It appears that the `is_diversion()` member function that callers
actually use comes from the `macro` and `string_iterator` classes in
"input.cpp".
* src/roff/troff/div.h (class diversion): Drop `is_diversion()`
declaration.
(macro_diversion::is_diversion)
(top_level_diversion::is_diversion): Drop definitions.
---
ChangeLog | 14 ++++++++++++++
src/roff/troff/div.h | 3 ---
2 files changed, 14 insertions(+), 3 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index b15869ef4..cfcb29b15 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,17 @@
+2026-04-14 G. Branden Robinson <[email protected]>
+
+ [troff]: Trivially refactor. Drop some code introduced in
+ commit dc3c168c3b, 2004-10-10. Per lcov(1) it's never used, and
+ deleting it does not adversely affect "make check". It appears
+ that the `is_diversion()` member function that callers actually
+ use comes from the `macro` and `string_iterator` classes in
+ "input.cpp".
+
+ * src/roff/troff/div.h (class diversion): Drop `is_diversion()`
+ declaration.
+ (macro_diversion::is_diversion)
+ (top_level_diversion::is_diversion): Drop definitions.
+
2026-04-15 G. Branden Robinson <[email protected]>
Ditch our local (outdated) copy of gnulib's "localcharset"
diff --git a/src/roff/troff/div.h b/src/roff/troff/div.h
index e77b0d484..c3257d2d9 100644
--- a/src/roff/troff/div.h
+++ b/src/roff/troff/div.h
@@ -63,7 +63,6 @@ public:
virtual void set_diversion_trap(symbol, vunits) = 0;
virtual void clear_diversion_trap() = 0;
virtual void copy_file(const char *filename) = 0;
- virtual bool is_diversion() = 0;
};
class macro;
@@ -89,7 +88,6 @@ public:
void set_diversion_trap(symbol, vunits);
void clear_diversion_trap();
void copy_file(const char *filename);
- bool is_diversion() { return true; }
};
struct trap {
@@ -149,7 +147,6 @@ public:
void set_diversion_trap(symbol, vunits);
void clear_diversion_trap();
void set_last_page() { last_page_count = page_count; }
- bool is_diversion() { return false; }
};
inline void top_level_diversion::set_page_offset(hunits h)
_______________________________________________
groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit