summaryrefslogtreecommitdiffstatshomepage
path: root/strings.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2008-12-28 00:34:20 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2008-12-28 00:34:20 +0000
commitf560c8171b3c347f410aed692168d4bd5ee00513 (patch)
tree49547698c8b614eaa9dc414e660bef7172edf3e3 /strings.c
parent990c4d95f389f1f47a9a5fa56c6009c6b2d7d2ff (diff)
downloadmandoc-f560c8171b3c347f410aed692168d4bd5ee00513.tar.gz
mandoc-f560c8171b3c347f410aed692168d4bd5ee00513.tar.zst
mandoc-f560c8171b3c347f410aed692168d4bd5ee00513.zip
*** empty log message ***
Diffstat (limited to 'strings.c')
-rw-r--r--strings.c23
1 files changed, 15 insertions, 8 deletions
diff --git a/strings.c b/strings.c
index 0125671d..36c1363c 100644
--- a/strings.c
+++ b/strings.c
@@ -1,4 +1,4 @@
-/* $Id: strings.c,v 1.2 2008/12/17 17:18:38 kristaps Exp $ */
+/* $Id: strings.c,v 1.3 2008/12/28 00:34:20 kristaps Exp $ */
/*
* Copyright (c) 2008 Kristaps Dzonsons <kristaps@kth.se>
*
@@ -25,15 +25,10 @@
#include "private.h"
int
-mdoc_isdelim(const char *p)
+mdoc_iscdelim(char p)
{
- if (0 == *p)
- return(0);
- if (0 != *(p + 1))
- return(0);
-
- switch (*p) {
+ switch (p) {
case('{'):
/* FALLTHROUGH */
case('.'):
@@ -66,6 +61,18 @@ mdoc_isdelim(const char *p)
}
+int
+mdoc_isdelim(const char *p)
+{
+
+ if (0 == *p)
+ return(0);
+ if (0 != *(p + 1))
+ return(0);
+ return(mdoc_iscdelim(*p));
+}
+
+
enum mdoc_sec
mdoc_atosec(size_t sz, const char **p)
{