=================================================================== RCS file: /cvs/texi2mdoc/extern.h,v retrieving revision 1.15 retrieving revision 1.18 diff -u -p -r1.15 -r1.18 --- texi2mdoc/extern.h 2015/02/25 14:37:17 1.15 +++ texi2mdoc/extern.h 2015/02/28 00:03:20 1.18 @@ -1,4 +1,4 @@ -/* $Id: extern.h,v 1.15 2015/02/25 14:37:17 kristaps Exp $ */ +/* $Id: extern.h,v 1.18 2015/02/28 00:03:20 kristaps Exp $ */ /* * Copyright (c) 2015 Kristaps Dzonsons * @@ -17,6 +17,21 @@ #ifndef EXTERN_H #define EXTERN_H +#if !defined(__BEGIN_DECLS) +# ifdef __cplusplus +# define __BEGIN_DECLS extern "C" { +# else +# define __BEGIN_DECLS +# endif +#endif +#if !defined(__END_DECLS) +# ifdef __cplusplus +# define __END_DECLS } +# else +# define __END_DECLS +# endif +#endif + /* * This defines each one of the Texinfo commands that we understand. * Obviously this only refers to native commands; overriden names are a @@ -301,6 +316,8 @@ struct texifile { char *map; /* allocated file buffer */ size_t mapsz; /* size of map */ size_t mapmaxsz; /* full size of map */ + size_t insplice; /* how many bytes left in splice */ + size_t depth; /* pasted macro recursive depth */ }; struct texi; @@ -410,8 +427,7 @@ void parseto(struct texi *, size_t *, const char *); void texiabort(struct texi *, const char *) __attribute__((noreturn)); enum texicmd - texicmd(struct texi *, size_t, - size_t *, struct teximacro **); + texicmd(struct texi *, size_t, size_t *, struct teximacro **); void texierr(struct texi *, const char *, ...) __attribute__((format(printf, 2, 3))) __attribute__((noreturn));