Added some escapes to generated RegExps