[LTP] [PATCH v4 1/3] Add Coccinelle helper scripts for reference
From: Li Wang <hidden>
Date: 2021-06-16 07:24:23
From: Li Wang <hidden>
Date: 2021-06-16 07:24:23
Hi Richard,
+for spatch_file in $*; do + case $spatch_file in + libltp-test-macro) + libltp_spatch --sp-file scripts/coccinelle/libltp-test-macro.cocci;; + libltp-test-macro-vars) + libltp_spatch --sp-file scripts/coccinelle/libltp-test-macro-vars.cocci \ + --ignore lib/tst_test.c;; + *) + tests_spatch --sp-file scripts/coccinelle/$spatch_file.cocci;;
Why here use the coccinelle/ path and add suffix with the spatch_file? Wouldn't this below more simple to us: scripts/coccinelle/$spatch_file.cocci ==> $spatch_file
+ esac +done
-- Regards, Li Wang