diff options
author | 2010-06-27 16:18:13 +0000 | |
---|---|---|
committer | 2010-06-27 16:18:13 +0000 | |
commit | dc95dcaff23f7235529d0b5d9866a252ca3f8c06 (patch) | |
tree | 33263f6d49184bc0c76b80cf9d91e5409c3d3e16 /man.3 | |
parent | dc649a73f967c1a61e60d2495f16d56db82eac57 (diff) | |
download | mandoc-dc95dcaff23f7235529d0b5d9866a252ca3f8c06.tar.gz mandoc-dc95dcaff23f7235529d0b5d9866a252ca3f8c06.tar.zst mandoc-dc95dcaff23f7235529d0b5d9866a252ca3f8c06.zip |
Following clue-stick applied by schwarze@, back out const-ness of regset
passed in to libmdoc and libman.
Fix mdoc.3 and man.3 EXAMPLE sections to include regset.
Add MDOC_SYNPRETTY flag cueing front-end to nicely format certain values
as if SEC_SYNOPSIS were the current section.
Diffstat (limited to 'man.3')
-rw-r--r-- | man.3 | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -1,4 +1,4 @@ -.\" $Id: man.3,v 1.20 2010/06/27 15:52:41 kristaps Exp $ +.\" $Id: man.3,v 1.21 2010/06/27 16:18:13 kristaps Exp $ .\" .\" Copyright (c) 2009-2010 Kristaps Dzonsons <kristaps@bsd.lv> .\" @@ -34,7 +34,7 @@ .Vt extern const char * const * man_macronames; .Ft "struct man *" .Fo man_alloc -.Fa "const struct regset *regs" +.Fa "struct regset *regs" .Fa "void *data" .Fa "int pflags" .Fa "mandocmsg msgs" @@ -291,14 +291,16 @@ on the finished parse tree with .Fn parsed . This example does not error-check nor free memory upon failure. .Bd -literal -offset indent +struct regset regs; struct man *man; struct man_node *node; char *buf; size_t len; int line; +bzero(®s, sizeof(struct regset)); line = 1; -man = man_alloc(NULL, 0, NULL); +man = man_alloc(®s, NULL, 0, NULL); buf = NULL; alloc_len = 0; |