aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/mdoc_macro.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2011-03-17 09:16:38 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2011-03-17 09:16:38 +0000
commit154c74a463b9f4d0c87a3161a60df5ce17c366c9 (patch)
tree71d24bb33de21624f0ddc202816da1a8e7025f9b /mdoc_macro.c
parent92c367a844f2f26d325d4ee6ca032894e94f7a06 (diff)
downloadmandoc-154c74a463b9f4d0c87a3161a60df5ce17c366c9.tar.gz
mandoc-154c74a463b9f4d0c87a3161a60df5ce17c366c9.tar.zst
mandoc-154c74a463b9f4d0c87a3161a60df5ce17c366c9.zip
Move mdoc_isdelim() into mandoc.h as mandoc_isdelim(). This allows the
removal of manual delimiter checks in html.c and term.c. Finally, add the escaped period as a closing delimiter, removing a TODO to this effect.
Diffstat (limited to 'mdoc_macro.c')
-rw-r--r--mdoc_macro.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/mdoc_macro.c b/mdoc_macro.c
index 925f4a19..740c1596 100644
--- a/mdoc_macro.c
+++ b/mdoc_macro.c
@@ -1,4 +1,4 @@
-/* $Id: mdoc_macro.c,v 1.101 2011/01/25 15:17:18 kristaps Exp $ */
+/* $Id: mdoc_macro.c,v 1.102 2011/03/17 09:16:38 kristaps Exp $ */
/*
* Copyright (c) 2008, 2009, 2010 Kristaps Dzonsons <kristaps@bsd.lv>
* Copyright (c) 2010 Ingo Schwarze <schwarze@openbsd.org>
@@ -599,7 +599,7 @@ append_delims(struct mdoc *m, int line, int *pos, char *buf)
else if (ARGS_EOLN == ac)
break;
- assert(DELIM_NONE != mdoc_isdelim(p));
+ assert(DELIM_NONE != mandoc_isdelim(p));
if ( ! mdoc_word_alloc(m, line, la, p))
return(0);
@@ -870,7 +870,7 @@ in_line(MACRO_PROT_ARGS)
* the word.
*/
- d = ARGS_QWORD == ac ? DELIM_NONE : mdoc_isdelim(p);
+ d = ARGS_QWORD == ac ? DELIM_NONE : mandoc_isdelim(p);
if (DELIM_NONE != d) {
/*
@@ -1061,7 +1061,7 @@ blk_full(MACRO_PROT_ARGS)
ARGS_PHRASE != ac &&
ARGS_PPHRASE != ac &&
ARGS_QWORD != ac &&
- DELIM_OPEN == mdoc_isdelim(p)) {
+ DELIM_OPEN == mandoc_isdelim(p)) {
if ( ! mdoc_word_alloc(m, line, la, p))
return(0);
continue;
@@ -1224,7 +1224,7 @@ blk_part_imp(MACRO_PROT_ARGS)
break;
if (NULL == body && ARGS_QWORD != ac &&
- DELIM_OPEN == mdoc_isdelim(p)) {
+ DELIM_OPEN == mandoc_isdelim(p)) {
if ( ! mdoc_word_alloc(m, line, la, p))
return(0);
continue;
@@ -1355,7 +1355,7 @@ blk_part_exp(MACRO_PROT_ARGS)
/* Flush out leading punctuation. */
if (NULL == head && ARGS_QWORD != ac &&
- DELIM_OPEN == mdoc_isdelim(p)) {
+ DELIM_OPEN == mandoc_isdelim(p)) {
assert(NULL == body);
if ( ! mdoc_word_alloc(m, line, la, p))
return(0);
@@ -1502,7 +1502,7 @@ in_line_argn(MACRO_PROT_ARGS)
if ( ! (MDOC_IGNDELIM & mdoc_macros[tok].flags) &&
ARGS_QWORD != ac &&
- 0 == j && DELIM_OPEN == mdoc_isdelim(p)) {
+ 0 == j && DELIM_OPEN == mandoc_isdelim(p)) {
if ( ! mdoc_word_alloc(m, line, la, p))
return(0);
continue;
@@ -1531,7 +1531,7 @@ in_line_argn(MACRO_PROT_ARGS)
if ( ! (MDOC_IGNDELIM & mdoc_macros[tok].flags) &&
ARGS_QWORD != ac &&
! flushed &&
- DELIM_NONE != mdoc_isdelim(p)) {
+ DELIM_NONE != mandoc_isdelim(p)) {
if ( ! rew_elem(m, tok))
return(0);
flushed = 1;