-
Notifications
You must be signed in to change notification settings - Fork 5
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
Why is a custom exporter needed? #73
Comments
I believe the main offender that prompted this issue was the magical import() method events used to have, but that has since been corrected. On the other hand, the topic of this ticket seems to be about Test::Stream::Exporter. I suspect the topic of the ticket is not actually correct, but in case it is I will switch gears and address that: Test::Stream::Exporter is used by any modules that need to export functions. This module provides some features I felt were necessary to achieve Test::Stream.
This last one is also important for performance, using HashBase showed notable, and critical speed improvements that allowed me to achieve performance required by the punch-list. Some of these features are now available in Exporter.pm, but not all, and not as far back as 5.8.1. |
I looked at how imports are used currently in Test::Stream. From what I can see, the main reason Test::Stream::Exporter seems to exist is to export unnamed subs from the source package. And those functions are unnamed because they are actually custom Test::Stream::Capabilities has a custom import function which serves no purpose. I suspect it primarily exists because of earlier versions of the module that did more work. But currently, the module would be better off with some I still strongly disagree with the UI of Test::Stream's import. The fact that it is optional does not sway my opinion at all. If |
I agree on Test::Stream::Capabilities, as it is now the custom import is overkill. iI would like to see a seperate ticket for that, and I will fix it, or accept tickets that do. I disagree on the Test::Stream UI (predictably), but I think that also deserves its own ticket and discussion seperate from here. |
I've heard a lot of questions about whether a custom exporter makes sense. We should discuss this as we go forward.
The text was updated successfully, but these errors were encountered: