--- In [email protected], "Sheri" <sheri...@...> wrote:
>
> --- In [email protected], "entropyreduction"
> <alancampbelllists+yahoo@> wrote:
> The problem with "literal" option should have shown up in
> regexPluginTest 43c, but the intending replacement string and option
> were not defined prior to or applied to the test. The literal option
> is supposed to bypass all evaluation and substitution applied to the
> replacement string.
>
> Examples:
>
> win.debug(?"Expected: \x22This subject had quotations.\x22")
> win.debug("Actual:", regex.pcrereplace(?X"X, ;;+
> ?X"This subject has quotations."X, ?"\x22", "literal"))
> ;The quotations should be literally replaced by backslash x 2 2.
> win.debug("")
> local notefolder = pprofolder++?"notes"
> win.debug("Expected: Notes folder: "++pprofolder++?"Notes")
> win.debug("Actual: ",regex.pcrereplace(?": \K", ?"Notes folder: ", ;;+
> notefolder, "literal"))
> ;there s/b no control characters or missing backslashes
Now long enough ago that I'll have to go read your docs to find out
what this was all about. Will do.
> here are the newer defines in pcre.h
> #define PCRE_BSR_ANYCRLF 0x00800000
> #define PCRE_BSR_UNICODE 0x01000000
> #define PCRE_JAVASCRIPT_COMPAT 0x02000000
> #define PCRE_CONFIG_BSR 8
Is that pcre 7.8? I better go get it, haven't downloaded their stuff
for ages.
> newish Compile-Time options
> PCRE_JAVASCRIPT_COMPAT
> PCRE_BSR_ANYCRLF
> PCRE_BSR_UNICODE
>
> newish Exec-Time options
> PCRE_BSR_ANYCRLF
> PCRE_BSR_UNICODE
>
> newish property of the pcre library:
> PCRE_CONFIG_BSR
> if zero, means backslash-R normally matches all Unicode line endings
> if one, means backslash-R normally matches CR, LF, or CRLF only