in reply to Re: Regexes and backslashes
in thread Regexes and backslashes
> If '\\n' (3 chars) is supposed to map to a single newline, what did you want '\n' to map to? '\n' (2 chars) or 'n'?
I don't want '\n' remapped at all. The only three things that I do want remapped are \, \; \\n - everything else should just be left as is.
> A hash isn't necessary if you use y///.
But I'm not trying to replace anything like a list of similar metacharacters. The whole challenge here is that I'm dealing with a set of things that are unlike each other: two sets of literal characters and one that is a literal plus a metacharacter. I'm just wondering if they can be handled by a common mechanism; that's what I'm asking about.
Thank you for trying.
-- 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 7stud (Deacon) on Feb 17, 2011 at 03:56 UTC | |
by Anonymous Monk on Feb 17, 2011 at 04:05 UTC | |
|
Re^3: Regexes and backslashes
by 7stud (Deacon) on Feb 17, 2011 at 03:56 UTC |