lkml.org 
[lkml]   [2018]   [Jul]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Subject[PATCH v2 2/8] Coccinelle: atomic_as_refcounter: Omit placeholder specifications from a SmPL constraint
From
Date
From: Markus Elfring <elfring@users.sourceforge.net>
Date: Mon, 16 Jul 2018 17:34:56 +0200

A string was enclosed by placeholder specifications for
regular expressions as constraints for metavariables in a script
for the semantic patch language.
The desired search functionality can be achieved also without
the notation “.*”. Thus delete it at a specific place.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
---
scripts/coccinelle/api/atomic_as_refcounter.cocci | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/coccinelle/api/atomic_as_refcounter.cocci b/scripts/coccinelle/api/atomic_as_refcounter.cocci
index 61fcaf5e45a3..46d27b2b1dff 100644
--- a/scripts/coccinelle/api/atomic_as_refcounter.cocci
+++ b/scripts/coccinelle/api/atomic_as_refcounter.cocci
@@ -12,7 +12,7 @@ virtual report
@r1 exists@
identifier a, x;
position p1, p2;
-identifier fname =~ ".*free.*";
+identifier fname =~ "free";
identifier fname2 =~ ".*destroy.*";
identifier fname3 =~ ".*del.*";
identifier fname4 =~ ".*queue_work.*";
--
2.18.0
\
 
 \ /
  Last update: 2018-07-16 19:27    [W:0.171 / U:0.140 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site