← Back to team overview

mudlet-makers team mailing list archive

[Bug 368708] Re: matches, multimatches, selectCaptureGroup Documentation

 

** Changed in: mudlet
       Status: New => Fix Released

-- 
matches, multimatches, selectCaptureGroup Documentation
https://bugs.launchpad.net/bugs/368708
You received this bug notification because you are a member of Mudlet
Makers, which is subscribed to Mudlet.

Status in Mudlet the MUD client: Fix Released

Bug description:
There appears to be a slight discrepancy in the documentation for these (and others that deal with capture groups). For ^(\d+)h, the (\d+) is documented to be matches[1], but it is not, it is matches[2]. matches[1] is the entire line, I believe. This filters down to all the different capture groups - even with the multimatches, the first group in the first regex pattern is not multimatches[1][2], it is multimatches[2][2]. Basically, you need to add 1 to the value expected by the documentation.



References