-/* $Id: libmdoc.h,v 1.13 2009/07/06 13:04:52 kristaps Exp $ */
+/* $Id: libmdoc.h,v 1.18 2009/07/12 20:50:08 kristaps Exp $ */
/*
* Copyright (c) 2008, 2009 Kristaps Dzonsons <kristaps@kth.se>
*
};
enum merr {
- ETAILWS,
+ ETAILWS = 0,
ECOLEMPTY,
EARGVPARM,
EQUOTPARM,
ENOCALL,
EBODYPROL,
EPROLBODY,
- ESPACE,
ETEXTPROL,
ENOBLANK,
ETOOLONG,
ELISTTYPE,
EDISPTYPE,
EMULTIDISP,
- ESECNAME,
EMULTILIST,
+ ESECNAME,
+ ENAMESECINC,
EARGREP,
EBOOL,
ECOLMIS,
ESECOOO,
ESECREP,
EBADSTAND,
- ENAMESECINC,
ENOMULTILINE,
EMULTILINE,
ENOLINE,
EPROLOOO,
EPROLREP,
EBADMSEC,
+ EBADSEC,
EFONT,
EBADDATE,
+ ENUMFMT,
ENOWIDTH,
- EBADSEC,
EUTSNAME,
- ENUMFMT,
EOBS,
EMACPARM,
EIMPBRK,
EIGNE,
EOPEN,
- EQUOT,
+ EQUOTPHR,
ENOCTX,
- ENOPARMS
+ ESPACE,
+ ELIB,
+ MERRMAX
};
#define MACRO_PROT_ARGS struct mdoc *mdoc, int tok, int line, \
#define mdoc_pwarn(m, l, p, t) \
mdoc_err((m), (l), (p), 0, (t))
#define mdoc_nerr(m, n, t) \
- mdoc_err((m), (n)->line, (n)->pos, 0, (t))
-#define mdoc_nwarn(m, n, t) \
mdoc_err((m), (n)->line, (n)->pos, 1, (t))
+#define mdoc_nwarn(m, n, t) \
+ mdoc_err((m), (n)->line, (n)->pos, 0, (t))
int mdoc_err(struct mdoc *, int, int, int, enum merr);
int mdoc_verr(struct mdoc *, int, int, const char *, ...);
time_t mdoc_atotime(const char *);
size_t mdoc_macro2len(int);
+const char *mdoc_a2att(const char *);
+const char *mdoc_a2lib(const char *);
+const char *mdoc_a2st(const char *);
const char *mdoc_a2arch(const char *);
const char *mdoc_a2vol(const char *);
const char *mdoc_a2msec(const char *);