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

Adding Dry::Container::Mixin#each_pair #25

Closed
wants to merge 1 commit into from
Closed

Adding Dry::Container::Mixin#each_pair #25

wants to merge 1 commit into from

Conversation

jeremyf
Copy link
Collaborator

@jeremyf jeremyf commented Oct 14, 2016

In discussions with other developers, it was felt that being able to
iterate over not just the registered keys, but to see what was
registered would be very helpful. This is a step toward doing that.

In discussions with other developers, it was felt that being able to
iterate over not just the registered keys, but to see what was
registered would be very helpful. This is a step toward doing that.
@jeremyf
Copy link
Collaborator Author

jeremyf commented Oct 14, 2016

Adding issue concerning rbx-2 (#27)

@AMHOL
Copy link
Member

AMHOL commented Oct 14, 2016

Thanks for the PR.

We have discussed this in the past and decided against adding it as nobody had a specific need for it, could you explain your use-case please?

# toward doing that.
def each_pair(&block)
config.resolver.each_pair(_container, &block)
self
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still not sure on the feature as a whole yet, but I think that returning self here is a bad idea, it doesn't seem like a good candidate for method chaining and encourages mutation in some form or another

@solnic
Copy link
Member

solnic commented Oct 15, 2016

Why each_pair instead of just each yielding a key and an object?

@AMHOL
Copy link
Member

AMHOL commented Dec 6, 2016

@jeremyf going to close this issue due to inactivity, please respond if this is still an issue that you think needs addressing and we can re-open

@AMHOL AMHOL closed this Dec 6, 2016
@jeremyf
Copy link
Collaborator Author

jeremyf commented Dec 6, 2016

@AMHOL I switched to #each with a new pull request #30

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.

3 participants