in reply to Re: Regexes and backslashes
in thread Regexes and backslashes
I did indeed mean the string to be as it was; it's actually text that I'm getting from an email that I want to parse. The part where I said "Ugh" was specifically because I'm not a fan of 'eval'ing arbitrary text; that's a a really, really bad idea. :)
There are lots of ways to solve "the problem" (which isn't really a problem; I mean, two substitutions and it's done.) I was just curious to see if, given that original string - one with single backslashes in it - a capture mechanism could be constructed along the lines of what I was trying to do. At the moment, it looks like the answer is 'no' - but I hope that someone here will prove me wrong.
-- Education is not the filling of a pail, but the lighting of a fire. -- W. B. Yeats
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Regexes and backslashes
by AnomalousMonk (Archbishop) on Feb 16, 2011 at 04:08 UTC |