Skip to content

spec: the introduction to 'For statements with range clause' fails to mention range-over-func #67977

Closed
@gazerro

Description

@gazerro

The introduction of the paragraph on For statements with range clause fails to mention the range over function:

A "for" statement with a "range" clause iterates through all entries of an array, slice, string or map, values received on a channel, or integer values from zero to an upper limit [Go 1.22]. [...]

and also

The expression on the right in the "range" clause is called the range expression, its core type must be an array, pointer to an array, slice, string, map, channel permitting receive operations, or an integer.

Metadata

Metadata

Assignees

Labels

DocumentationIssues describing a change to documentation.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions