-
Notifications
You must be signed in to change notification settings - Fork 28
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
Enhancement: perl: allow to pass parameters to callbacks #63
Comments
How about this:
And if you want to force a type, then |
that looks right to me, and I'd need the same for init-func and deinit-func |
Yeah, I'd do it in a general way, so the same stuff can be reused for other |
For init-func, and deinit func i wouldn't do the same, because at init-time and deinit-time there is no message, on which you can apply your template. That's why we use constant globals in lua, for example. I would use the lua-style config in all scripted destinations. We will see if the semantics will differ, or we can unify them, too. (In lua, you cannot use named parameters from C, only positional ones, but in python, you can do something like that. Every language has some dict/hash/table-like structure, so I would go for that direction for scripted destinations). |
Yeah, for init/deinit, it wouldn't be a template. But similar syntax. How it gets pushed down to the interpreter, is another matter. |
It would feel more natural (IMHO) to pass parameters to callbacks instead of going through value-pairs, maybe something like:
or alternatively
The text was updated successfully, but these errors were encountered: