cocci: simplify check for trivial format strings