[PATCH v2 0/2] docs: kdoc: convert tracepoint parsing to CMatch

From: Omokefe Emmanuel Onanaroghene

Date: Fri Oct 23 2026 - 09:05:56 EST


Mauro suggested handling tracepoint and syscall declarations with pure
CMatch transformations, and keeping any nested-comma tokenizer correction
in a separate patch. This series follows that split.

Patch 1 fixes CMatch argument grouping so delimiters inside nested
expressions do not split the outer macro arguments. Patch 2 replaces the
procedural syscall and tracepoint munging with CMatch transformations,
including support for the TRACE_EVENT_FN() family, and adds parser tests.


Omokefe Emmanuel Onanaroghene (2):
docs: kdoc: handle nested commas in CMatch arguments
docs: kdoc: handle TRACE_EVENT_FN() with CMatch

tools/lib/python/kdoc/c_lex.py | 22 ++++++-
tools/lib/python/kdoc/kdoc_parser.py | 94 ++-------------------------
tools/lib/python/kdoc/xforms_lists.py | 39 +++++++++++
tools/unittests/test_cmatch.py | 7 ++
tools/unittests/test_kdoc_parser.py | 56 ++++++++++++++++
5 files changed, 129 insertions(+), 89 deletions(-)


base-commit: 90d9f76ccb72ec024ef476b4229f3dd1957d7b26
--
2.43.0