From 453b89b7ef90bec43feecdd5d29c7ed381fdb90c Mon Sep 17 00:00:00 2001 From: schwarze Date: Sat, 30 Apr 2022 15:08:56 +0000 Subject: [PATCH] Add comments to some of the enum roff_tok values; particularly useful for values that have non-obvious semantics like ROFF_MAX, ROFF_cblock, ROFF_RENAMED, and TOKEN_NONE; no code change. --- usr.bin/mandoc/roff.h | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/usr.bin/mandoc/roff.h b/usr.bin/mandoc/roff.h index aefeafcc78f..e04ced7c622 100644 --- a/usr.bin/mandoc/roff.h +++ b/usr.bin/mandoc/roff.h @@ -1,6 +1,6 @@ -/* $OpenBSD: roff.h,v 1.56 2020/04/08 11:54:14 schwarze Exp $ */ +/* $OpenBSD: roff.h,v 1.57 2022/04/30 15:08:56 schwarze Exp $ */ /* - * Copyright (c) 2013-2015, 2017-2020 Ingo Schwarze + * Copyright (c) 2013-2015,2017-2020,2022 Ingo Schwarze * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons * * Permission to use, copy, modify, and distribute this software for any @@ -71,7 +71,7 @@ enum roff_type { }; enum roff_tok { - ROFF_br = 0, + ROFF_br = 0, /* Beginning of roff(7) requests. */ ROFF_ce, ROFF_fi, ROFF_ft, @@ -83,8 +83,8 @@ enum roff_tok { ROFF_sp, ROFF_ta, ROFF_ti, - ROFF_MAX, - ROFF_ab, + ROFF_MAX, /* End of requests that generate nodes. */ + ROFF_ab, /* Requests only used during preprocessing. */ ROFF_ad, ROFF_af, ROFF_aln, @@ -313,11 +313,11 @@ enum roff_tok { ROFF_writec, ROFF_writem, ROFF_xflag, - ROFF_cblock, - ROFF_RENAMED, - ROFF_USERDEF, - TOKEN_NONE, - MDOC_Dd, + ROFF_cblock, /* Block end marker "..". */ + ROFF_RENAMED, /* New name of a renamed request or macro. */ + ROFF_USERDEF, /* User defined macro. */ + TOKEN_NONE, /* Undefined macro or text/tbl/eqn/comment node. */ + MDOC_Dd, /* Beginning of mdoc(7) macros. */ MDOC_Dt, MDOC_Os, MDOC_Sh, @@ -438,8 +438,8 @@ enum roff_tok { MDOC__U, MDOC_Ta, MDOC_Tg, - MDOC_MAX, - MAN_TH, + MDOC_MAX, /* End of mdoc(7) macros. */ + MAN_TH, /* Beginning of man(7) macros. */ MAN_SH, MAN_SS, MAN_TP, @@ -476,7 +476,7 @@ enum roff_tok { MAN_UE, MAN_MT, MAN_ME, - MAN_MAX + MAN_MAX /* End of man(7) macros. */ }; /* -- 2.20.1