aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/regexp/regexp.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/regexp/regexp.go b/src/regexp/regexp.go
index f975bb3894..7d56bd6b8e 100644
--- a/src/regexp/regexp.go
+++ b/src/regexp/regexp.go
@@ -46,7 +46,7 @@
// the match of the first parenthesized subexpression, and so on.
//
// If 'Index' is present, matches and submatches are identified by byte index
-// pairs within the input string: result[2*n:2*n+1] identifies the indexes of
+// pairs within the input string: result[2*n:2*n+2] identifies the indexes of
// the nth submatch. The pair for n==0 identifies the match of the entire
// expression. If 'Index' is not present, the match is identified by the text
// of the match/submatch. If an index is negative or text is nil, it means that