You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
detect errors at CT instead of RT if both regex pattern and replace pattern are given at CT
eg: echo "abcfoodef".replace(re"f(o)o", "[$2]") should give a CT error
error in replacement pattern should be more useful instead of just invalidFormatString ; in above example could show:
error in replace pattern "[$2]" at column 2: out of bound error 2: expected values 1 through 1
$0 could be supported with meaning of "whole match"
detect errors at CT instead of RT if both regex pattern and replace pattern are given at CT
eg:
echo "abcfoodef".replace(re"f(o)o", "[$2]")
should give a CT errorerror in replacement pattern should be more useful instead of just
invalidFormatString
; in above example could show:error in replace pattern
"[$2]"
at column 2: out of bound error 2: expected values 1 through 1$0
could be supported with meaning of "whole match"other patterns could be used for before match and after match, as in https://dlang.org/phobos/std_regex.html#Replace%20format%20string ; either using D's
or perhaps using more explicit / easier to remember names, eg
$(pre)
$(post)
The text was updated successfully, but these errors were encountered: