More benefits from higher level structures for coccicheck scripts?

From: Markus Elfring
Date: Fri Feb 21 2025 - 05:12:19 EST


Hello,

Various source code was assigned to functions (or function-like macros).
Common functionality is stored at selected places.
Thus there is a desire to increase the corresponding usage.

Some scripts were constructed also according to the means of the semantic
patch language.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/dev-tools/coccinelle.rst?h=v6.14-rc3#n71

It can be seen that some of these SmPL scripts share also program structures.

* Operation modes need to be determined.

* Special source code items should be detected somehow.

* Data output should be provided.



Would you be looking for the support of higher level structures for
coccicheck scripts?

Is there a need for placeholders (or variables) which could be filled from
other advanced information sources so that selected data processing
will eventually not be mapped to separate SmPL script files to achieve more
desirable transformations?

Regards,
Markus