Skip to content
This repository was archived by the owner on Sep 1, 2020. It is now read-only.
This repository was archived by the owner on Sep 1, 2020. It is now read-only.

capitalization convention #19

Open
@StefanKarpinski

Description

@StefanKarpinski

Once upon a time (truth be told, I can't find the email thread), it was decided that lowercase iterator functions would all be eager, while the corresponding uppercase name would be an Iterator object, which is thus lazy. After this was resolved and agreed to, it was immediately ignored, so we have kind of a free-for-all going on. I still think that was a good idea. Thus, Map(f,itr) would produce a Map iterator that does mapping lazily, whereas map(f,itr) is equivalent to collect(Map(f,itr)), but can of course be more efficient. Most iterators in this package define a type for lazy iteration and then immediately define a function that just constructs the type, thus constructing a lazy iterator. Of course, for many of the iterators in this package, it isn't even sensible to evaluate them eagerly. In any case, it would be nice to have some consistent convention about eager versus lazy iterator evaluation.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions