summaryrefslogtreecommitdiff
path: root/usr.bin/mandoc/mdoc_macro.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin/mandoc/mdoc_macro.c')
-rw-r--r--usr.bin/mandoc/mdoc_macro.c17
1 files changed, 5 insertions, 12 deletions
diff --git a/usr.bin/mandoc/mdoc_macro.c b/usr.bin/mandoc/mdoc_macro.c
index 4b657f1dddd..16bc80b0163 100644
--- a/usr.bin/mandoc/mdoc_macro.c
+++ b/usr.bin/mandoc/mdoc_macro.c
@@ -1,4 +1,4 @@
-/* $Id: mdoc_macro.c,v 1.6 2009/07/12 19:05:52 schwarze Exp $ */
+/* $Id: mdoc_macro.c,v 1.7 2009/07/12 20:30:27 schwarze Exp $ */
/*
* Copyright (c) 2008, 2009 Kristaps Dzonsons <kristaps@kth.se>
*
@@ -29,13 +29,6 @@ enum mwarn {
WOBS
};
-enum merr {
- EOPEN,
- EQUOT,
- ENOCTX,
- ENOPARMS
-};
-
#define REWIND_REWIND (1 << 0)
#define REWIND_NOHALT (1 << 1)
#define REWIND_HALT (1 << 2)
@@ -205,13 +198,13 @@ perr(struct mdoc *mdoc, int line, int pos, enum merr type)
case (EOPEN):
p = "explicit scope still open on exit";
break;
- case (EQUOT):
+ case (EQUOTPHR):
p = "unterminated quotation";
break;
case (ENOCTX):
p = "closure has no prior context";
break;
- case (ENOPARMS):
+ case (ENOLINE):
p = "unexpect line arguments";
break;
}
@@ -728,7 +721,7 @@ blk_exp_close(MACRO_PROT_ARGS)
return(0);
return(rew_expblock(mdoc, tok, line, ppos));
}
- return(perr(mdoc, line, ppos, ENOPARMS));
+ return(perr(mdoc, line, ppos, ENOLINE));
}
if ( ! rew_subblock(MDOC_BODY, mdoc, tok, line, ppos))
@@ -1450,7 +1443,7 @@ phrase(struct mdoc *mdoc, int line, int ppos, char *buf)
else if ('\\' != buf[i - 1])
break;
if (0 == buf[i])
- return(perr(mdoc, line, la, EQUOT));
+ return(perr(mdoc, line, la, EQUOTPHR));
quoted = 1;
} else
for ( ; buf[i]; i++)