allow \0 characters in regular expressions and input streams