1
0
mirror of https://github.com/golang/go synced 2024-11-07 20:56:16 -07:00
go/src/regexp
Russ Cox f50448f531 regexp: reword Match documentation to be more like Find
Before:

  // Find returns a slice holding the text of the leftmost match in b of the regular expression.

  // Match checks whether a textual regular expression matches a byte slice.

After:

  // Match reports whether the byte slice b contains any match of the regular expression re.

The use of different wording for Find and Match always makes me think
that Match required the entire string to match while Find clearly allows
a substring to match.

This CL makes the Match wording correspond more closely to Find,
to try to avoid that confusion.

Change-Id: I97fb82d5080d3246ee5cf52abf28d2a2296a5039
Reviewed-on: https://go-review.googlesource.com/123736
Run-TryBot: Russ Cox <rsc@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2018-07-13 18:52:46 +00:00
..
syntax all: update comment URLs from HTTP to HTTPS, where possible 2018-06-01 21:52:00 +00:00
testdata
all_test.go
backtrack.go
example_test.go regexp: examples for Regexp.FindIndex and Regexp.FindAllSubmatchIndex methods 2018-06-30 01:04:30 +00:00
exec2_test.go
exec_test.go
exec.go all: update comment URLs from HTTP to HTTPS, where possible 2018-06-01 21:52:00 +00:00
find_test.go
onepass_test.go
onepass.go all: use strings.Builder instead of bytes.Buffer where appropriate 2018-03-26 23:05:53 +00:00
regexp.go regexp: reword Match documentation to be more like Find 2018-07-13 18:52:46 +00:00