Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

docs: kdoc: remove the brcount floor in process_proto_type()

Putting the floor under brcount does not change the output in any way, just
remove it.

Change the termination test from ==0 to <=0 to prevent infinite loops in
case somebody does something truly wacko in the code.

Signed-off-by: Jonathan Corbet <corbet@lwn.net>

+1 -3
+1 -3
scripts/lib/kdoc/kdoc_parser.py
··· 1609 1609 self.entry.brcount += r.group(2).count('{') 1610 1610 self.entry.brcount -= r.group(2).count('}') 1611 1611 1612 - self.entry.brcount = max(self.entry.brcount, 0) 1613 - 1614 - if r.group(2) == ';' and self.entry.brcount == 0: 1612 + if r.group(2) == ';' and self.entry.brcount <= 0: 1615 1613 self.dump_declaration(ln, self.entry.prototype) 1616 1614 self.reset_state(ln) 1617 1615 break