JuliaCollections / JuliaCollections/IterTools.jl

reverse iterators for Julia 0.7

Open
#14 0 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Julia
Stars
160
Forks
30
PR merge metrics
No merged PRs in 30d

Description

Now that 0.7 has reverse iteration (https://github.com/JuliaLang/julia/pull/24187), it would be nice to support that in the IterTools iterators where it makes sense:

  • define Iterators.reverse(itr::SomeIterType) in cases where the reverse iterator is easily written in terms of some other iterator type. (e.g. if itr "wraps" around another iterator, just call Iterators.reverse on the "inner" iterator).

  • define start/next/done methods for Iterators.Reverse{SomeIterType} in cases where you need a specialized iteration protocol.

For examples, see https://github.com/JuliaLang/julia/blob/master/base/iterators.jl

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Inspect the IterTools iterator types and compare their reverse-iteration behavior with Julia's base/iterators.jl. Start with cases where Iterators.reverse can delegate to an inner iterator, then identify types needing specialized Reverse iteration methods. Done means the applicable IterTools iterators support reverse iteration under Julia 0.7's protocol.

Written by the indexing model from the issue text.

Assessment

Tech stack
julia
Domain
tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.