coccinelle: misc: minmax: suppress patch generation for err returns
authorDenis Efremov <efremov@linux.com>
Wed, 28 Apr 2021 06:03:50 +0000 (09:03 +0300)
committerJulia Lawall <Julia.Lawall@inria.fr>
Sat, 1 May 2021 19:27:10 +0000 (21:27 +0200)
commitaeb300c1dbfc77b493728f608dd14d6814676546
tree1b4bddc69fd4193e1e262b5fdf96b14a164bd5ed
parent32c465613959248a8db8a1458d65a266411ddccc
coccinelle: misc: minmax: suppress patch generation for err returns

There is a standard idiom for "if 'ret' holds an error, return it":
return ret < 0 ? ret : 0;

Developers prefer to keep the things as they are because stylistic
change to "return min(ret, 0);" breaks readability.

Let's suppress automatic generation for this type of patches.

Signed-off-by: Denis Efremov <efremov@linux.com>
scripts/coccinelle/misc/minmax.cocci