diff options
Diffstat (limited to 'src/net/http/internal/http2/errors.go')
| -rw-r--r-- | src/net/http/internal/http2/errors.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/net/http/internal/http2/errors.go b/src/net/http/internal/http2/errors.go index 35c34b7ba5..58822972bc 100644 --- a/src/net/http/internal/http2/errors.go +++ b/src/net/http/internal/http2/errors.go @@ -104,14 +104,14 @@ func (e StreamError) As(target any) bool { if dstType.NumField() != numField { return false } - for i := 0; i < numField; i++ { + for i := range numField { sf := srcType.Field(i) df := dstType.Field(i) if sf.Name != df.Name || !sf.Type.ConvertibleTo(df.Type) { return false } } - for i := 0; i < numField; i++ { + for i := range numField { df := dst.Field(i) df.Set(src.Field(i).Convert(df.Type())) } |
