in reply to Re^2: Partial Xor in string
in thread Partial Xor in string
Yes, you're correct, I was thinking that % is escaped with a backslash, not another %. Memory lapse.
In that case the pattern might look like this:
split /(?<!%)(%[^%\s]+)/I'm still a little curious what problem we're really solving. Why parse and encrypt a sprintf format specifier in the first place? A format string should be considered code, not data accepted from the outside world. What's the underlying need here?
perl -E 'my $f = shift @ARGV; say sprintf $f, "foo"' '%9999999999s'
(consumes 1.3GB RAM)
Dave
|
|---|