Re: [PATCH] kernel-doc parser mishandles declarations split into lines

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> Am 31.08.2017 um 00:38 schrieb Jonathan Corbet <corbet@xxxxxxx>:
> 
> On Fri, 16 Jun 2017 21:27:48 +0200
> Markus Heiser <markus.heiser@xxxxxxxxxxx> wrote:
> 
>> Reported by Johannes Berg [1].  Problem here: function
>> process_proto_type() concatenates the striped lines of declaration
>> without any whitespace. A one-liner of::
>> 
>> struct something {
>>       struct foo
>>       bar;
>>       };
>> 
>> has to be::
>> 
>> struct something {struct foo bar;};
>> 
>> Without the patching process_proto_type(), the result missed the space
>> between 'foo' and 'bar'::
>> 
>> struct something {struct foobar;};
>> 
>> Bugfix of process_proto_type() brings next error when blank lines
>> between enum declaration::
>> 
>> warning: Enum value ' ' not described in enum 'foo'
>> 
>> Problem here: dump_enum() does not strip leading whitespaces from
>> the concatenated string (with the new additional space from
>> process_proto_type).
>> 
>> [1] https://www.mail-archive.com/linux-doc@xxxxxxxxxxxxxxx/msg12410.html
>> 
>> Signed-off-by: Markus Heiser <markus.heiser@xxxxxxxxxxx>
> 
> So somehow I missed this one entirely, not sure what happened.  (OTOH the
> original problem report was never sent to me).
> 
> I applied it now, and ran it - it makes a lot of changes to the output!

Right. FYI: I tested a similar patch of my kernel-doc py-version [2]
against the whole source, the impact was huge: 1,405 changes in 245
files. Here is the diff:

   https://github.com/return42/sphkerneldoc/commit/56554e5f16c68d46d9c361e46540ce48ec1a9f27#diff-523d26ea9da1bb7b97d2b763c75367e9

Thanks for applying!

-- Markus --

[2] https://github.com/return42/linuxdoc/commit/f11bbd5

 
> The problem mostly came up, it seems, with function-pointer members, which
> are often too long to fit on one line.  The result is a definite
> improvement - thanks!
> 
> jon

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux