Re: [RFC] Docbook: allow warning on unused documentation

From: Randy Dunlap
Date: Thu Aug 26 2010 - 13:11:41 EST


On Thu, 26 Aug 2010 18:51:16 +0200 Johannes Berg wrote:

> On Thu, 2010-08-26 at 09:37 -0700, Randy Dunlap wrote:
> > On Wed, 18 Aug 2010 15:09:27 +0200 Johannes Berg wrote:
> >
> > > When you don't use !E or !I but only !F, then
> > > it's very easy to miss including some functions,
> > > structs etc. in documentation. To help finding
> > > which ones were missed, allow printing out the
> > > unused ones as warnings.
> >
> > How do I test this? Do I need to add !A to some source file?
>
> Yeah, like to Documentation/DocBook/mac80211.tmpl you could add
> !Ainclude/net/mac80211.h

Yes, I see. That output looks useful.

How about using !C (for "check") instead of !A ?


> > > +#define _GNU_SOURCE
> >
> > Can you explain why that is needed? (curious)
>
> Yeah, I used asprintf somewhere.

ack.

> > > +static void find_all_symbols(char *filename)
> > > +{
> > > + char *vec[4]; /* kerneldoc -docbook -function "section" file NULL */
> >
> > incorrect comment??
>
> Oops, yes:
>
> > > + vec[0] = KERNELDOC;
> > > + vec[1] = LIST;
> > > + vec[2] = filename;
> > > + vec[3] = NULL;


---
~Randy
*** Remember to use Documentation/SubmitChecklist when testing your code ***
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/