change the global wflag, but use a per pattern flag derived from it. Fixes usage of grep with multiple -w arguments.