diff options
author | Frantisek Sumsal <frantisek@sumsal.cz> | 2020-10-04 12:29:43 +0200 |
---|---|---|
committer | Frantisek Sumsal <frantisek@sumsal.cz> | 2020-10-04 12:32:21 +0200 |
commit | 135a9868a7551fba29a928f7a8dd9761486f9a5b (patch) | |
tree | 1be5a898d1ed55620d0bfba15069e97e6bde0a49 /coccinelle | |
parent | 1813613fedaf65d54bae8048cf9f922ec643fbd7 (diff) | |
download | systemd-135a9868a7551fba29a928f7a8dd9761486f9a5b.tar.gz |
coccinelle: skip strjoin transformation in test_strjoin()
Diffstat (limited to 'coccinelle')
-rw-r--r-- | coccinelle/strjoin.cocci | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/coccinelle/strjoin.cocci b/coccinelle/strjoin.cocci index 675760e37a..46f70c4c23 100644 --- a/coccinelle/strjoin.cocci +++ b/coccinelle/strjoin.cocci @@ -1,16 +1,15 @@ @@ -expression list args; -@@ -- strjoin(args, NULL); -+ strjoin(args); -@@ +position p : script:python() { p[0].current_element != "test_strjoin" }; expression t; expression list args; @@ -- t = strjoin(args, NULL); +( +- strjoin@p(args, NULL); ++ strjoin(args); +| +- t = strjoin@p(args, NULL); + t = strjoin(args); -@@ -expression list args; -@@ -- return strjoin(args, NULL); +| +- return strjoin@p(args, NULL); + return strjoin(args); +) |