qorelanguage / qore

Qore Programming Language
GNU General Public License v2.0
61 stars 10 forks source link

it's not possible to escape an escape character before a $ sign in a regex substitution expression #777

Closed davidnich closed 8 years ago

davidnich commented 8 years ago

ex:

qore -ne 'string str = "hello1234_()"; str =~ s/([^[:alnum:]])/\\$1/g; printf("%s\n", str);'
hello1234\$1\$1\$1
davidnich commented 8 years ago

the last patch broke escape handling for other cases in the regex subst target string - working on it