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

Add Interleave#54

Closed
oxinabox wants to merge 8 commits intoJuliaCollections:masterfrom
oxinabox:master
Closed

Add Interleave#54
oxinabox wants to merge 8 commits intoJuliaCollections:masterfrom
oxinabox:master

Conversation

@oxinabox
Copy link
Copy Markdown
Member

Interleave is the complement to chain.
It takes from each iterator in turn.
It is required to implement things like Minikanren.

PS: I may have messed up the squash. I've not used rebase before. and I got fairly confused.

oxinabox and others added 8 commits February 23, 2016 15:18
"""
Interleave is the transpose of chain.
It returns one element from each of the iterators in turn.
If one of the interators runs dry then it is skippted
eg:
```
collect(interleave([1,2,3],[10,20,30,40,50],[0.1,0.2]))
>[1,10,0.1,2,20,0.2,3,30,40,50]
```
"""
Added the Interleave iterator

"""
Interleave is the transpose of chain.
It returns one element from each of the iterators in turn.
If one of the interators runs dry then it is skippted
eg:
```
collect(interleave([1,2,3],[10,20,30,40,50],[0.1,0.2]))
>[1,10,0.1,2,20,0.2,3,30,40,50]
```
"""

Add Interleave documentation

Improve doc formatting

remove duplicate import in interleave

Remove odd type
@tkelman
Copy link
Copy Markdown
Contributor

tkelman commented Feb 23, 2016

The main thing you probably missed is the last step should have been a force push. Without that, github complains about non-fast-forward, so you tried the merge which led to this still having multiple copies of the commits. Try the rebase again until git log only shows your single commit and the diff looks right in git show, then add --force to your git push. Note that it's generally advisable to do pull requests from working branches other than master of your fork, and only do force pushes to temporary working branches (force pushes can be problematic on public master/release branches, if anyone else is pulling from the repository).

@oxinabox
Copy link
Copy Markdown
Member Author

Cancelling this and making new squashed PR

@oxinabox oxinabox closed this Apr 28, 2016
@oxinabox oxinabox mentioned this pull request Apr 28, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants