Re: [PATCH] scripts: kernel-doc: Check existence of FILE arg

From: Tomasz Warniełło
Date: Wed Feb 23 2022 - 09:17:11 EST


On Wed, 23 Feb 2022 22:59:01 +0900
Akira Yokosawa <akiyks@xxxxxxxxx> wrote:

> On Wed, 23 Feb 2022 14:47:13 +0100,
> Tomasz Warniełło wrote:
> > On Wed, 23 Feb 2022 15:07:30 +0900
> > Akira Yokosawa <akiyks@xxxxxxxxx> wrote:
> >
> >> Currently, when no FILE argument is given following switches such
> >> as -man, -rst, and -none, kernel-doc ends up in the error of (long
> >> msg from perl folded):
> >>
> >> Use of uninitialized value $ARGV[0] in pattern match (m//)
> >> at ./scripts/kernel-doc line 438.
> >
> > It's a warning not an error.
>
> Good catch!
>
> Will amend in v2 with proper attribution.
>
> Thanks Akira

I'd include this in a series regulating all the CLI syntax - all those
mutual exclusions and arg parsing error handling, etc. At the moment they
exist only in the documentation.

But I'm not sure this is the right moment to do this. Have you seen
my RFC thread? I'd wait until the water stabilises and see the result.
This script may be phased out - how soon, I don't know. Unless you want
to do this purely for sport.

Tomasz