Re: Getting the start / end of string in regex through match objects

2006-01-09 Thread ankit
Thanks frederik, :) -- http://mail.python.org/mailman/listinfo/python-list

Getting the start / end of string in regex through match objects

2006-01-09 Thread ankit
I want to get the start and end of all the patterns mattched in regex. I know I can get it with start() and end() fn of matched objects. But re.search() return the match object of first matching regex in the string. I want all match objects in that string Here is the string : tmplstr = """ ${name

Re: Getting the start / end of string in regex through match objects

2006-01-09 Thread Fredrik Lundh
"ankit" wrote: >I want to get the start and end of all the patterns mattched in regex. > I know I can get it with start() and end() fn of matched objects. But > re.search() return the match object of first matching regex in the > string. I want all match objects in that string for m in re.fin