From: Robert Griesemer Date: Wed, 17 Feb 2021 05:05:08 +0000 (-0800) Subject: spec: every type has a method set (minor clarification) X-Git-Tag: go1.17beta1~1471 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=078f08f0ee1eb6cb172fc1f9d53f34c5783e522d;p=gostls13.git spec: every type has a method set (minor clarification) The spec states that a type "may" have a method set associated with it. Yet every type has a method set, which may be empty. This is clarified later in the same paragraph. Be clear in the first sentence as well. Per the suggestion from https://github.com/DQNEO. Fixes #44318. Change-Id: I6097b1c7062853e404b7fead56d18a7f9c576fc3 Reviewed-on: https://go-review.googlesource.com/c/go/+/292853 Trust: Robert Griesemer Run-TryBot: Robert Griesemer Reviewed-by: Ian Lance Taylor --- diff --git a/doc/go_spec.html b/doc/go_spec.html index 59c9ce3c43..e22fabd699 100644 --- a/doc/go_spec.html +++ b/doc/go_spec.html @@ -1,6 +1,6 @@ @@ -830,7 +830,7 @@ The underlying type of []B1, B3, and B4 i

Method sets

-A type may have a method set associated with it. +A type has a (possibly empty) method set associated with it. The method set of an interface type is its interface. The method set of any other type T consists of all methods declared with receiver type T.