summaryrefslogtreecommitdiffstats
path: root/mdoc_argv.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2009-07-17 12:27:49 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2009-07-17 12:27:49 +0000
commiteb5bbab95cc20d925a72a535dc2e2a9146579b92 (patch)
treed4dbdc8222075aeecc00e1e97852e35bf641aea6 /mdoc_argv.c
parent3446c98bd2e82211a7d2dd91a4f256a3695e91fb (diff)
downloadmandoc-eb5bbab95cc20d925a72a535dc2e2a9146579b92.tar.gz
Removed EARGVPARM (superfluous, overly error-generating).
Added `sp' handler.
Diffstat (limited to 'mdoc_argv.c')
-rw-r--r--mdoc_argv.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/mdoc_argv.c b/mdoc_argv.c
index 2ddafa65..1cdd0582 100644
--- a/mdoc_argv.c
+++ b/mdoc_argv.c
@@ -37,7 +37,6 @@
#define ARGS_QUOTED (1 << 0)
#define ARGS_DELIM (1 << 1)
#define ARGS_TABSEP (1 << 2)
-#define ARGS_ARGVLIKE (1 << 3)
#define ARGV_NONE (1 << 0)
#define ARGV_SINGLE (1 << 1)
@@ -127,7 +126,7 @@ static int mdoc_argflags[MDOC_MAX] = {
0, /* Ot */
ARGS_DELIM, /* Pa */
0, /* Rv */
- ARGS_DELIM | ARGS_ARGVLIKE, /* St */
+ ARGS_DELIM, /* St */
ARGS_DELIM, /* Va */
ARGS_DELIM, /* Vt */
ARGS_DELIM, /* Xr */
@@ -232,9 +231,6 @@ mdoc_argv(struct mdoc *m, int line, int tok,
assert(' ' != buf[*pos]);
- if ('-' != buf[*pos] || ARGS_ARGVLIKE & mdoc_argflags[tok])
- return(ARGV_WORD);
-
/* Parse through to the first unescaped space. */
i = *pos;
@@ -268,8 +264,6 @@ mdoc_argv(struct mdoc *m, int line, int tok,
/* XXX - restore saved zeroed byte. */
if (sv)
buf[*pos - 1] = sv;
- if ( ! mdoc_pwarn(m, line, i, EARGVPARM))
- return(ARGV_ERROR);
return(ARGV_WORD);
}
@@ -407,10 +401,6 @@ args(struct mdoc *m, int line, int *pos,
if ( ! mdoc_pwarn(m, line, *pos, EQUOTPARM))
return(ARGS_ERROR);
- if ( ! (fl & ARGS_ARGVLIKE) && '-' == buf[*pos])
- if ( ! mdoc_pwarn(m, line, *pos, EARGVPARM))
- return(ARGS_ERROR);
-
/*
* If the first character is a delimiter and we're to look for
* delimited strings, then pass down the buffer seeing if it