On Mon, Oct 05, 2009 at 05:11:16AM +0200, Aristotle Pagaltzis wrote: > * Eric Brine <ikegami@adaelis.com> [2009-10-05 01:30]: > > I noticed you didn't touch \s, which is the one that troubles > > me (too?). I often use \d and \w in patterns that are captured. > > It's good to match tightly, so I agree with you. \s, on the > > other hand, matches parts of the input I usually wish to > > discard. Having it behave laxly (i.e. match characters such as > > NBSP) would benefit me. > > That’s a sore point for me. Even the fact that \s matches newline > often annoys me. I wish there was a shorthand for [ \t] which is > what I usually want when I use \s – though I often use \s anyway > for the brevity when it’s not a huge issue. It seems you want to match horizontal whitespace. I use \h when I need that, that will match space, tab, the no-break space, and a handful of Unicode spaces. AbigailThread Previous | Thread Next