Skip to content

Commit

Permalink
net/url: fix PathUnescape, QueryUnescape number grammar
Browse files Browse the repository at this point in the history
They do not convert a plural into a singular.
(Introduced recently, in CL 77050.)

Change-Id: I3b6c4d03b1866d4133e90b8ab05e8d4bfbd55125
Reviewed-on: https://go-review.googlesource.com/82078
Run-TryBot: Russ Cox <rsc@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
  • Loading branch information
rsc authored and bradfitz committed Dec 6, 2017
1 parent bb22a69 commit 358d7c9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/net/url/url.go
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ func shouldEscape(c byte, mode encoding) bool {
}

// QueryUnescape does the inverse transformation of QueryEscape,
// converting 3-byte encoded substrings of the form "%AB" into the
// converting each 3-byte encoded substring of the form "%AB" into the
// hex-decoded byte 0xAB. It also converts '+' into ' ' (space).
// It returns an error if any % is not followed by two hexadecimal
// digits.
Expand All @@ -173,7 +173,7 @@ func QueryUnescape(s string) (string, error) {
}

// PathUnescape does the inverse transformation of PathEscape,
// converting 3-byte encoded substrings of the form "%AB" into the
// converting each 3-byte encoded substring of the form "%AB" into the
// hex-decoded byte 0xAB. It also converts '+' into ' ' (space).
// It returns an error if any % is not followed by two hexadecimal
// digits.
Expand Down

0 comments on commit 358d7c9

Please sign in to comment.