[Cocci] Checking the support for source code transformations with special characters

Julia Lawall julia.lawall at lip6.fr
Mon May 14 21:41:46 CEST 2018

On Mon, 14 May 2018, SF Markus Elfring wrote:

> >> I have noticed a moment ago that a blank line is not marked by the SmPL
> >> asterisk operator (for a small source code example) so far.
> >>
> >> Can such whitespace characters be also preserved there anyhow?
> >
> > No.  Whitespace is never preserved in metavariables.
> How does such information fit to the following wording in the documentation?
> https://github.com/coccinelle/coccinelle/blob/848f85e256516330c06f5fd8dc782b854ed9aa03/docs/manual/introduction.tex#L4
> “… automate repetitive source-to-source style-preserving program transformations …”

When Coccinelle adds code, it makes an effort to conform to the
indentation of the context in which the code is placed, not the context
from which the code was removed.  The goal is to preserve the stule of the
code as a whole.


More information about the Cocci mailing list