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 some ineffective code

The code testing for a pointer declaration in process_name() has no actual
effect on subsequent actions; remove it.

Reviewed-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Link: https://lore.kernel.org/r/20250606163438.229916-8-corbet@lwn.net

-5
-5
scripts/lib/kdoc/kdoc_parser.py
··· 1237 1237 parenthesis = r"(?:\(\w*\))?" # optional parenthesis on function 1238 1238 decl_end = r"(?:[-:].*)" # end of the name part 1239 1239 1240 - # test for pointer declaration type, foo * bar() - desc 1241 - r = KernRe(fr"^{decl_start}([\w\s]+?){parenthesis}?\s*{decl_end}?$") 1242 - if r.search(line): 1243 - self.entry.identifier = r.group(1) 1244 - 1245 1240 # Test for data declaration 1246 1241 r = KernRe(r"^\s*\*?\s*(struct|union|enum|typedef)\b\s*(\w*)") 1247 1242 r2 = KernRe(fr"^{decl_start}{fn_type}(?:define\s+)?(\w+)\s*{parenthesis}\s*{decl_end}?$")