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.

scripts/kernel-doc.py: properly handle out_section for ReST

There is a difference at the way DOC sections are output with
the include mode. Handle such difference properly.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Link: https://lore.kernel.org/r/935d00c6a7c45b25a8be72fad6183fe5a8476cd2.1744106242.git.mchehab+huawei@kernel.org

authored by

Mauro Carvalho Chehab and committed by
Jonathan Corbet
9235ec5e 408269ae

+4 -4
+4 -4
scripts/lib/kdoc/kdoc_output.py
··· 315 315 if section in self.nosymbol: 316 316 continue 317 317 318 - if not self.out_mode == self.OUTPUT_INCLUDE: 319 - if out_docblock: 318 + if out_docblock: 319 + if not self.out_mode == self.OUTPUT_INCLUDE: 320 320 self.data += f".. _{section}:\n\n" 321 - 322 - if not self.symbol: 323 321 self.data += f'{self.lineprefix}**{section}**\n\n' 322 + else: 323 + self.data += f'{self.lineprefix}**{section}**\n\n' 324 324 325 325 self.print_lineno(section_start_lines.get(section, 0)) 326 326 self.output_highlight(sections[section])