This repository was archived by the owner on Jan 5, 2024. It is now read-only.
Fixes for google issues 11, 14, and 16#2
Open
rassilon wants to merge 10 commits intodstanek:masterfrom
Open
Conversation
Author
There was a problem hiding this comment.
The specs command uses the sys module, but this import was missing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Apologies for the messy commit history in the pull request.
I would have rebased but you're not supposed to do that for published history (i.e. google code).
You may notice I reverted the provider instance caching.
I don't think you can do that without verifying that the provider exists in the current binder's (or parent's) Singleton scope instance. (The fix for issue 11.)
The fix for issue 11 essentially means you need to register a scope to the binder by calling binder.bind_scope before you can bind something into the scope.
The binder.get_binding change if I recall correctly was to simplify life in the multibinder so that the multibinder class didn't have constructed Key instances. (Since the keys are so complex in multibinder.)
The reason for the complexity is that all items in the multibinding have individual bindings in the binder (as well as a dynamic provider to inject the multibinder).
The key of the dynamic provider class is:
The key of each of the multibinder items is:
The core concept of these keys is _RealElement which is essentially:
The new _ _ str _ _ method for Annotation is just as important since it becomes the name of _RealElement.
Thanks again for snake-guice,
Bill