Skip to content

Documentation for ExactSizeIterator does not make clear that len() should change with iteration #98721

Closed
@alice-i-cecile

Description

@alice-i-cecile

Reading between the lines on ExactSizeIterator (and investigating other implementations), it appears that the value of the returned len() should change as iteration occurs.

This is very subtle, and was missed by our entire team, see bevyengine/bevy#5149.

This information should be discussed prominently in the docs.

Metadata

Metadata

Assignees

Labels

A-docsArea: Documentation for any part of the project, including the compiler, standard library, and tools

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions