Hello, I have tried another tiny script out for the semantic patch language (according to the software combination “Coccinelle 1.0.8-00029-ga549b9f0”).
@display@ int i; @@ return * -i ; Are the following search results worth for further software development considerations? https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/log/drivers/net/wireless/intersil/hostap/hostap_main.c elfring@Sonne:~/Projekte/Linux/next-patched> spatch ~/Projekte/Coccinelle/janitor/show_returns_of_negative_integers2.cocci drivers/net/wireless/intersil/hostap/hostap_main.c … @@ -328,7 +327,6 @@ int hostap_set_encryption(local_info_t * u16 val, old_val; int i, keylen, len, idx; char keybuf[WEP_KEY_LEN + 1]; - enum { NONE, WEP, OTHER } encrypt_type; idx = local->crypt_info.tx_keyidx; if (local->crypt_info.crypt[idx] == NULL || … https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/log/sound/drivers/opl3/opl3_midi.c elfring@Sonne:~/Projekte/Linux/next-patched> spatch ~/Projekte/Coccinelle/janitor/show_returns_of_negative_integers2.cocci sound/drivers/opl3/opl3_midi.c … @@ -136,7 +136,6 @@ static int opl3_get_voice(struct snd_opl /* This is our "allocation cost" table */ enum { - FREE = 0, CHEAP, EXPENSIVE, END }; /* Keeps track of what we are finding */ … Why are source code places presented which do not contain a key word I was looking for this test approach? Regards, Markus _______________________________________________ Cocci mailing list [email protected] https://systeme.lip6.fr/mailman/listinfo/cocci
