Lines Matching refs:n
37 #define CHKARGS struct man *man, struct man_node *n
102 struct man_node *n;
105 n = man->last;
106 if (n->flags & MAN_VALID)
108 n->flags |= MAN_VALID;
110 switch (n->type) {
112 check_text(man, n);
115 check_root(man, n);
122 cp = man_valids + n->tok;
124 (*cp)(man, n);
137 n->line, n->pos, NULL);
143 n->line, n->pos, NULL);
153 mandoc_normdate(man->parse, NULL, n->line, n->pos);
165 cp = n->string;
168 n->line, n->pos + (p - cp), NULL);
175 if (n->nchild == 0)
177 n->line, n->pos, "OP");
178 else if (n->nchild > 2) {
179 n = n->child->next->next;
181 n->line, n->pos, "OP ... %s", n->string);
189 if (n->type == MAN_HEAD && n->child == NULL)
191 n->line, n->pos, "UR");
192 check_part(man, n);
201 if (0 == n->nchild)
205 cp = n->child->string;
237 n->line, n->pos, "ft %s", cp);
246 if (n->type == MAN_BODY && n->child == NULL)
248 n->line, n->pos, man_macronames[n->tok]);
255 switch (n->type) {
257 if (0 == n->body->nchild)
258 man_node_delete(man, n);
261 if (0 == n->nchild)
263 man->parse, n->line, n->pos,
264 "%s empty", man_macronames[n->tok]);
267 if (n->nchild)
269 man->parse, n->line, n->pos,
270 "%s %s%s", man_macronames[n->tok],
271 n->child->string,
272 n->nchild > 1 ? " ..." : "");
283 switch (n->type) {
285 if (0 == n->head->nchild && 0 == n->body->nchild)
286 man_node_delete(man, n);
289 if (0 == n->parent->head->nchild && 0 == n->nchild)
291 man->parse, n->line, n->pos,
292 "%s empty", man_macronames[n->tok]);
314 nb = n;
318 n = n->child;
319 if (n && n->string) {
320 for (p = n->string; '\0' != *p; p++) {
325 man->parse, n->line,
326 n->pos + (p - n->string),
327 "TH %s", n->string);
331 man->meta.title = mandoc_strdup(n->string);
340 if (n)
341 n = n->next;
342 if (n && n->string)
343 man->meta.msec = mandoc_strdup(n->string);
352 if (n)
353 n = n->next;
354 if (n && n->string && '\0' != n->string[0]) {
356 mandoc_strdup(n->string) :
357 mandoc_normdate(man->parse, n->string,
358 n->line, n->pos);
362 n ? n->line : nb->line,
363 n ? n->pos : nb->pos, "TH");
368 if (n && (n = n->next))
369 man->meta.source = mandoc_strdup(n->string);
376 if (n && (n = n->next))
377 man->meta.vol = mandoc_strdup(n->string);
382 if (n != NULL && (n = n->next) != NULL)
384 n->line, n->pos, "TH ... %s", n->string);
399 n->line, n->pos, "nf");
410 n->line, n->pos, "fi");
428 n = n->child;
430 if (NULL == n || MAN_TEXT != n->type)
433 s = n->string;
465 n = n->child;
467 if (NULL == n || MAN_TEXT != n->type)
470 s = n->string;
476 nn = n->next;
493 if (NULL != n->prev)
496 switch (n->parent->tok) {
500 mandoc_vmsg(MANDOCERR_PAR_SKIP, man->parse, n->line, n->pos,
501 "%s after %s", man_macronames[n->tok],
502 man_macronames[n->parent->tok]);
509 man_node_delete(man, n);