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

SetterInjection has hard-coded constructor name #43

Closed
dakkar opened this issue Mar 30, 2015 · 2 comments
Closed

SetterInjection has hard-coded constructor name #43

dakkar opened this issue Mar 30, 2015 · 2 comments

Comments

@dakkar
Copy link
Contributor

dakkar commented Mar 30, 2015

ConstructorInjection uses the MOP (plus override) to find the constructor to call, but SetterInjection always calls new. Should I factor out the constructor_name attribute and use it in both injections?

dakkar added a commit to dakkar/BreadBoard that referenced this issue Mar 31, 2015
dakkar added a commit to dakkar/BreadBoard that referenced this issue Mar 31, 2015
@stevan
Copy link
Owner

stevan commented Mar 31, 2015

Looks sensible to me, however I don't think anyone ever used SetterInjection. It is more annoying then it is worth and BlockInjection is a far more readable/understandable way to accomplish the same thing and have your actual intent be clearer.

@yanick yanick closed this as completed in d5699f0 Jun 6, 2015
yanick added a commit that referenced this issue Jun 6, 2015
@yanick
Copy link
Collaborator

yanick commented Jun 6, 2015

Merged in. Thanks! :-)

yanick added a commit that referenced this issue Mar 28, 2016
  - Add test messages to tests which did not have them, (#50, Alex
    Balhatchet)

  [ DOCUMENTATION ]
    - add missing module abstracts. (GH#49, Alex Balhatchet, GH#16,
      Sterling Hanenkamp)

  [ ENHANCEMENTS ]
    - SetterInjection can now accept any constructor. (#43, dakkar)

  [ STATISTICS ]
    - code churn: 37 files changed, 462 insertions(+), 395 deletions(-)
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

No branches or pull requests

3 participants