- experimental: added two new attributes to the match object:

"lastgroup" is the name of the last matched capturing group,
  "lastindex" is the index of the same group.  if no group was
  matched, both attributes are set to None.

  the (?P#) feature will be removed in the next relase.
This commit is contained in:
Fredrik Lundh 2000-07-02 22:25:39 +00:00
parent c9c02c4cf3
commit c2301730b8
4 changed files with 38 additions and 13 deletions

View file

@ -21,6 +21,7 @@ typedef struct {
PyObject* code; /* link to the code string object */
int groups;
PyObject* groupindex;
PyObject* indexgroup;
/* compatibility */
PyObject* pattern; /* pattern source (or None) */
int flags; /* flags used when compiling pattern source */