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

Refactor Push() to remove need for int argument #9

Open
zyvitski opened this issue Nov 4, 2016 · 0 comments
Open

Refactor Push() to remove need for int argument #9

zyvitski opened this issue Nov 4, 2016 · 0 comments

Comments

@zyvitski
Copy link

zyvitski commented Nov 4, 2016

From using the CTPL library I have noticed that the fact that push() requires the first argument of the function being pushed makes using the library difficult at times.

In a way it forces anyone using the library to force their interface to conform to the need for that int parameter. This can be achieved by either conforming your interface to work with the pool or by wrapping your target function with another function that adds the leading int parameter.

I believe that it would make the library more accessible, transparent and user friendly if an overload of push() was provided that allowed you to push a function onto the pool without the need for the leading int parameter.

I would be willing to work up the changes and add them as a pull request if desired, but I wanted to run the idea by first.

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

1 participant