-.B "#include <mLib/tvec.h>
-
-
-
-extern int tvec_serialize(const struct tvec_reg */*rv*/,
- const struct tvec_regdef */*regs*/,
- unsigned /*nr*/, size_t /*regsz*/,
- void **/*p_out*/, size_t */*sz_out*/);
-
-extern int tvec_deserialize(struct tvec_reg */*rv*/,
- const struct tvec_regdef */*regs*/,
- unsigned /*nr*/, size_t /*regsz*/,
- const void */*p*/, size_t /*sz*/);
-
+.B "#include <mLib/tvec.h>"
+.PP
+.ta 2n
+.B "union tvec_misc {"
+.B " const void *p;"
+.B " long i;"
+.B " unsigned long u;"
+.B " double f;"
+.B "};"
+.B "enum {"
+.B " TVMISC_PTR,"
+.B " TVMISC_INT,"
+.B " TVMISC_UINT,"
+.B " TVMISC_FLT,"
+.B " ...,"
+.B " TVMISC_LIMIT,"
+.B "};"
+.PP
+.ta 2n +2n
+.B "union tvec_regval {"
+.B " long i;"
+.B " unsigned long u;"
+.B " void *p;"
+.B " double f;"
+.B " struct { char *p; size_t sz; } text;"
+.B " struct { unsigned char *p; size_t sz; } bytes;"
+.B " struct {"
+.B " unsigned char *p; size_t sz;"
+.B " size_t a, m;"
+.B " size_t off;"
+.B " } buf;"
+.B " TVEC_REGSLOTS"
+.B "};"
+.B "struct tvec_reg {"
+.B " unsigned f;"
+.B " union tvec_regval v;"
+.B "};"
+.B "#define TVRF_LIVE ..."
+.PP
+.ta 2n
+.B "struct tvec_regdef {"
+.B " const char *name;"
+.B " const struct tvec_regty *ty;"
+.B " unsigned i;"
+.B " unsigned f;"
+.B " union tvec_misc arg;"
+.B "};"
+.B "#define TVRF_OPT ..."
+.B "#define TVRF_ID ..."
+.B "#define TVEC_ENDREGS ..."
+.PP
+.B "struct tvec_state;"
+.PP
+.B "struct tvec_env;"
+.ta \w'\fBtypedef void tvec_testfn('u
+.BI "typedef void tvec_testfn(const struct tvec_reg *" in ,
+.BI " struct tvec_reg *" out ,
+.BI " void *" ctx );
+.B "struct tvec_test {"
+.B " const char *name;"
+.B " const struct tvec_regdef *regs;"
+.B " const struct tvec_env *env;"
+.B " tvec_testfn *fn;"
+.B "};"
+.B "#define TVEC_ENDTESTS ..."
+.PP
+.ta 2n
+.B "struct tvec_config {"
+.B " const struct tvec_test *tests;"
+.B " unsigned nrout, nreg;"
+.B " size_t regsz;"
+.B "};"
+.B "struct tvec_output;"
+.PP
+.ta \w'\fBvoid tvec_begin('u
+.BI "void tvec_begin(struct tvec_state *" tv_out ,
+.BI " const struct tvec_config *" config ,
+.BI " struct tvec_output *" o );
+.BI "int tvec_end(struct tvec_state *" tv );
+.BI "int tvec_read(struct tvec_state *" tv ", const char *" infile ", FILE *" fp );
+.PP
+.BI "extern struct tvec_output *tvec_humanoutput(FILE *" fp );
+.BI "extern struct tvec_output *tvec_tapoutput(FILE *" fp );
+.BI "extern struct tvec_output *tvec_dfltoutput(FILE *" fp );
+.fi