[BACK]Return to validate.c CVS log [TXT][DIR] Up to [cvsweb.bsd.lv] / mandoc

Diff for /mandoc/Attic/validate.c between version 1.22 and 1.23

version 1.22, 2009/01/09 15:07:04 version 1.23, 2009/01/09 15:15:31
Line 32  struct valids {
Line 32  struct valids {
 };  };
   
   
   static  int     pre_display(struct mdoc *, struct mdoc_node *);
 static  int     pre_prologue(struct mdoc *, struct mdoc_node *);  static  int     pre_prologue(struct mdoc *, struct mdoc_node *);
 static  int     pre_prologue(struct mdoc *, struct mdoc_node *);  static  int     pre_prologue(struct mdoc *, struct mdoc_node *);
 static  int     pre_prologue(struct mdoc *, struct mdoc_node *);  static  int     pre_prologue(struct mdoc *, struct mdoc_node *);
Line 46  static v_post posts_sh[] = { post_headchild_err_ge1, 
Line 47  static v_post posts_sh[] = { post_headchild_err_ge1, 
 static  v_post  posts_ss[] = { post_headchild_err_ge1, NULL };  static  v_post  posts_ss[] = { post_headchild_err_ge1, NULL };
 static  v_post  posts_pp[] = { post_elemchild_warn_eq0, NULL };  static  v_post  posts_pp[] = { post_elemchild_warn_eq0, NULL };
 static  v_post  posts_dd[] = { post_elemchild_err_ge1, NULL };  static  v_post  posts_dd[] = { post_elemchild_err_ge1, NULL };
   static  v_post  posts_display[] = { post_headchild_err_ge1, NULL };
   
   
 const   struct valids mdoc_valids[MDOC_MAX] = {  const   struct valids mdoc_valids[MDOC_MAX] = {
Line 56  const struct valids mdoc_valids[MDOC_MAX] = {
Line 58  const struct valids mdoc_valids[MDOC_MAX] = {
         { NULL, posts_sh }, /* Sh */ /* FIXME: preceding Pp. */          { NULL, posts_sh }, /* Sh */ /* FIXME: preceding Pp. */
         { NULL, posts_ss }, /* Ss */ /* FIXME: preceding Pp. */          { NULL, posts_ss }, /* Ss */ /* FIXME: preceding Pp. */
         { NULL, posts_pp }, /* Pp */ /* FIXME: proceeding... */          { NULL, posts_pp }, /* Pp */ /* FIXME: proceeding... */
         { NULL, NULL }, /* D1 */          { pre_display, posts_display }, /* D1 */
         { NULL, NULL }, /* Dl */          { pre_display, posts_display }, /* Dl */
         { NULL, NULL }, /* Bd */ /* FIXME: preceding Pp. */          { pre_display, NULL }, /* Bd */ /* FIXME: preceding Pp. */
         { NULL, NULL }, /* Ed */          { NULL, NULL }, /* Ed */
         { NULL, NULL }, /* Bl */ /* FIXME: preceding Pp. */          { NULL, NULL }, /* Bl */ /* FIXME: preceding Pp. */
         { NULL, NULL }, /* El */          { NULL, NULL }, /* El */
Line 202  post_headchild_err_ge1(struct mdoc *mdoc)
Line 204  post_headchild_err_ge1(struct mdoc *mdoc)
         if (mdoc->last->child)          if (mdoc->last->child)
                 return(1);                  return(1);
         return(mdoc_err(mdoc, ERR_ARGS_GE1));          return(mdoc_err(mdoc, ERR_ARGS_GE1));
   }
   
   
   static int
   pre_display(struct mdoc *mdoc, struct mdoc_node *node)
   {
           struct mdoc_node *n;
   
           for (n = mdoc->last; n; n = n->parent)
                   if (MDOC_BLOCK == n->type)
                           if (MDOC_Bd == n->data.block.tok)
                                   break;
           if (NULL == n)
                   return(1);
           return(mdoc_verr(mdoc, node, ERR_SCOPE_NONEST));
 }  }
   
   

Legend:
Removed from v.1.22  
changed lines
  Added in v.1.23

CVSweb