From b515ea6c4c885e69aebc0e97046ef428a4c9903d Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Thu, 23 Apr 2015 16:17:44 +0000 Subject: Unify mdoc_deroff() and man_deroff() into a common function deroff(). No functional change except that for mdoc(7), it now skips leading escape sequences just like it already did for man(7). Escape sequences rarely occur in mdoc(7) code and if they do, skipping them is an improvement in this context. Minus 30 lines of code. --- roff.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'roff.h') diff --git a/roff.h b/roff.h index cf29d6d1..750ccbe2 100644 --- a/roff.h +++ b/roff.h @@ -157,3 +157,9 @@ struct roff_man { enum roff_sec lastnamed; /* Last standard section seen. */ enum roff_next next; /* Where to put the next node. */ }; + +__BEGIN_DECLS + +void deroff(char **, const struct roff_node *); + +__END_DECLS -- cgit v1.2.3-56-ge451