+1 > -----Original Message----- > From: Ilya Maximets <[email protected]> > Sent: Monday, January 14, 2019 5:05 PM > To: [email protected]; Ben Pfaff <[email protected]> > Cc: Aaron Conole <[email protected]>; Ophir Munk > <[email protected]>; Ilya Maximets <[email protected]> > Subject: [PATCH] checkpatch: Check style of FOREACH loops. > > Current checkpatch rules matches only OVS 'FOR_EACH' loops. > This change will apply same style checks for DPDK iterators like > 'RTE_ETH_FOREACH_MATCHING_DEV () {}'. > > Signed-off-by: Ilya Maximets <[email protected]> > --- > utilities/checkpatch.py | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/utilities/checkpatch.py b/utilities/checkpatch.py index > d8bd34b1f..57ef5e6f3 100755 > --- a/utilities/checkpatch.py > +++ b/utilities/checkpatch.py > @@ -142,7 +142,7 @@ def reset_counters(): > # something in parentheses (usually an expression) then a left curly brace. > # > # 'do' almost qualifies but it's also used as "do { ... } while (...);". > -__parenthesized_constructs = 'if|for|while|switch|[_A-Z]+FOR_EACH[_A- > Z]*' > +__parenthesized_constructs = 'if|for|while|switch|[_A- > Z]+FOR_*EACH[_A-Z]*' > > __regex_added_line = re.compile(r'^\+{1,2}[^\+][\w\W]*') > __regex_subtracted_line = re.compile(r'^\-{1,2}[^\-][\w\W]*') > -- > 2.17.1
_______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
