Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change compose to work for more than two funcitons #56

Closed
wants to merge 1 commit into from

Conversation

stoeffel
Copy link
Contributor

  • allow two or more functions
  • pass all arguments to the first function

refs #53

- allow two or more functions
- pass all arguments to the first function

refs tjmehta#53
@tjmehta
Copy link
Owner

tjmehta commented Feb 10, 2015

@stoeffel hey I don't think this is necessary. Check out the thread here: #30

@stoeffel
Copy link
Contributor Author

You're right it's not necessary, because you can do this:

[f, g, h, i, j, k, l].reduce(compose);

but the cool thing about my solution is that you can still use reduce, but also can do this:

compose(f, g, h, i, j, k, l);

But I get your point. Please close this PR if you think it's not a gain.

btw. Thanks for your work.

@tjmehta
Copy link
Owner

tjmehta commented Feb 10, 2015

I do like how you made it still work with reduce. I hate to throw out completed work, but I'd just rather not add it as it doesn't follow the convention already layed out in 101 (and, or, etc).

I really appreciate your contribution.

@tjmehta tjmehta closed this Feb 10, 2015
@stoeffel
Copy link
Contributor Author

I hate to throw out completed work

No problem. It was fun to do.

I really appreciate your contribution.

Thanks 🙇

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants