docs: kdoc: replace NestedMatch with CMatch

Our previous approach to solve nested structs were to use
NestedMatch. It works well, but adding support to parse delimiters
is very complex.

Instead, use CMatch, which uses a C tokenizer, making the code more
reliable and simpler.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Message-ID: <900bff66f8093402999f9fe055fbfa3fa33a8d8b.1773770483.git.mchehab+huawei@kernel.org>
This commit is contained in:
Mauro Carvalho Chehab
2026-03-17 19:09:34 +01:00
committed by Jonathan Corbet
parent c22aa12c76
commit 600079fdcf
2 changed files with 17 additions and 16 deletions

View File

@@ -14,7 +14,7 @@ import re
from pprint import pformat
from kdoc.c_lex import CTokenizer
from kdoc.kdoc_re import NestedMatch, KernRe
from kdoc.kdoc_re import KernRe
from kdoc.kdoc_item import KdocItem
#