Re: [q-lang-users] regex
Brought to you by:
agraef
From: Keith T. <kaz...@ea...> - 2007-07-03 00:10:24
|
Hello Eddie -- --- ed...@ri... wrote: - I cannot find in the manual and GNU Regex manual - how to do a nongreedy match. >From the resource of resources (Wikipedia) wrt. (modern) POSIX regexp: [1] "modern regular expression tools allow a quantifier to be specified as non-greedy, by putting a question mark after the quantifier"; and more specifically, [2] ? Match the last "block" zero or one times - "ba?" matches "b" or "ba". HTH! Albert: I AGREE with John: PCRE over POSIX regexp IS the way to go. =) It is also worth noting that the switch to PCRE will bring Q another step closer to mainstream scripting languages. IMHO this is a GOOD THING. ;-) Cheers, Keith |