diff options
author | Russ Cox <rsc@golang.org> | 2022-02-03 14:05:46 -0500 |
---|---|---|
committer | Russ Cox <rsc@golang.org> | 2022-04-05 17:52:29 +0000 |
commit | 81431c7aa7c5d782e72dec342442ea7664ef1783 (patch) | |
tree | 34b0a65bf5ddf8168133801e5ed7ae142b212dbf /src/regexp | |
parent | b4cabaf8c094da8387ac6274706fe4850d77ebc6 (diff) | |
download | go-81431c7aa7c5d782e72dec342442ea7664ef1783.tar.gz go-81431c7aa7c5d782e72dec342442ea7664ef1783.zip |
all: replace `` and '' with “ (U+201C) and ” (U+201D) in doc comments
go/doc in all its forms applies this replacement when rendering
the comments. We are considering formatting doc comments,
including doing this replacement as part of the formatting.
Apply it to our source files ahead of time.
For #51082.
Change-Id: Ifcc1f5861abb57c5d14e7d8c2102dfb31b7a3a19
Reviewed-on: https://go-review.googlesource.com/c/go/+/384262
Trust: Russ Cox <rsc@golang.org>
Run-TryBot: Russ Cox <rsc@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Diffstat (limited to 'src/regexp')
-rw-r--r-- | src/regexp/exec_test.go | 4 | ||||
-rw-r--r-- | src/regexp/syntax/prog.go | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/regexp/exec_test.go b/src/regexp/exec_test.go index a6e833050b..1694230345 100644 --- a/src/regexp/exec_test.go +++ b/src/regexp/exec_test.go @@ -52,8 +52,8 @@ import ( // submatch indices. An unmatched subexpression formats // its pair as a single - (not illustrated above). For now // each regexp run produces two match results, one for a -// ``full match'' that restricts the regexp to matching the entire -// string or nothing, and one for a ``partial match'' that gives +// “full match” that restricts the regexp to matching the entire +// string or nothing, and one for a “partial match” that gives // the leftmost first match found in the string. // // Lines beginning with # are comments. Lines beginning with diff --git a/src/regexp/syntax/prog.go b/src/regexp/syntax/prog.go index 8583f55e54..ee71decb35 100644 --- a/src/regexp/syntax/prog.go +++ b/src/regexp/syntax/prog.go @@ -102,7 +102,7 @@ func EmptyOpContext(r1, r2 rune) EmptyOp { return op } -// IsWordChar reports whether r is consider a ``word character'' +// IsWordChar reports whether r is consider a “word character” // during the evaluation of the \b and \B zero-width assertions. // These assertions are ASCII-only: the word characters are [A-Za-z0-9_]. func IsWordChar(r rune) bool { |