MRAB pyt...@mrabarnett.plus.com writes:
On 2015-08-18 22:55, Ben Bacarisse wrote:
Neal Becker ndbeck...@gmail.com writes:
Trying regex 2015.07.19
I'd like to match recursive parenthesized expressions, with groups such that
'(a(b)c)'
would give
group(0) - '(a(b)c)'
group(1) - '(b)'
Neal Becker ndbeck...@gmail.com writes:
Trying regex 2015.07.19
I'd like to match recursive parenthesized expressions, with groups such that
'(a(b)c)'
would give
group(0) - '(a(b)c)'
group(1) - '(b)'
but that's not what I get
import regex
#r = r'\((?[^()]|(?R))*\)'
r =
On 2015-08-18 22:55, Ben Bacarisse wrote:
Neal Becker ndbeck...@gmail.com writes:
Trying regex 2015.07.19
I'd like to match recursive parenthesized expressions, with groups such that
'(a(b)c)'
would give
group(0) - '(a(b)c)'
group(1) - '(b)'
but that's not what I get
import regex
#r =
Trying regex 2015.07.19
I'd like to match recursive parenthesized expressions, with groups such that
'(a(b)c)'
would give
group(0) - '(a(b)c)'
group(1) - '(b)'
but that's not what I get
import regex
#r = r'\((?[^()]|(?R))*\)'
r = r'\(([^()]|(?R))*\)'
#r = r'\((?:[^()]|(?R))*\)'
m =
On 2015-08-18 15:25, Neal Becker wrote:
Trying regex 2015.07.19
I'd like to match recursive parenthesized expressions, with groups such that
'(a(b)c)'
would give
group(0) - '(a(b)c)'
group(1) - '(b)'
but that's not what I get
import regex
#r = r'\((?[^()]|(?R))*\)'
r = r'\(([^()]|(?R))*\)'
On 8/18/2015 10:25 AM, Neal Becker wrote:
Trying regex 2015.07.19
I'd like to match recursive parenthesized expressions, with groups such that
'(a(b)c)'
Extended regular expressions can only match strings in extended regular
languages. General nested expressions are too general for that.