[issue16990] re: match of nongreedy regex not grouping right

2013-01-17 Thread Jared Grubb
New submission from Jared Grubb: re.match matches, but the capture groups are empty. That's not possible. Python 2.7.2 (default, Oct 11 2012, 20:14:37) [GCC 4.2.1 Compatible Apple Clang 4.0 (tags/Apple/clang-418.0.60)] on darwin Type help, copyright, credits or license for more information.

[issue16990] re: match of nongreedy regex not grouping right

2013-01-17 Thread R. David Murray
R. David Murray added the comment: Wouldn't a non-greedy .* match the null string? -- nosy: +r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16990 ___

[issue16990] re: match of nongreedy regex not grouping right

2013-01-17 Thread Jared Grubb
Jared Grubb added the comment: Yes: re.match('.*', '') _sre.SRE_Match object at 0x107c6d308 re.match('.*?', '') _sre.SRE_Match object at 0x107c6d370 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16990

[issue16990] re: match of nongreedy regex not grouping right

2013-01-17 Thread R. David Murray
R. David Murray added the comment: So, group() is returning the correct value, then. -- resolution: - invalid stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16990

[issue16990] re: match of nongreedy regex not grouping right

2013-01-17 Thread Jared Grubb
Jared Grubb added the comment: You're right. My mistake. I thought match meant the full string must match, but in Python it means the beginning must match. Sorry for the noise. -- ___ Python tracker rep...@bugs.python.org