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
Introduced runtime dependency: use-package-verbose #149
Comments
Introduced by #96. |
@tarsius Can you address this? |
That seems reasonable to me. I don't really understand why it's desirable to use |
Jonas Bernoulli notifications@github.com writes:
Isn't that the whole point of implementing use-package as a compiler Not saying that's got to be the way it works, but if it is not a major Phil Hudson http://hudson-it.ddns.net |
Again:
I suppose something like this
? |
Well I suppose you could look at it that way, then again isn't the whole point of having a variable that changing its value actually has an effect? |
Or in other words:
So? That doesn't mean that the expansion cannot rely on global variables defined in the same package as the macro. You just have to load the library at runtime too so that the variable is defined - that doesn't result in the macro not being expanded until runtime. |
Jonas Bernoulli notifications@github.com writes:
Which is exactly the thing one does not want or expect to have to do. This problem has been addressed and fixed without controversy the Phil Hudson http://hudson-it.ddns.net |
Certainly not. One reason for using a macro is that the expansion can be done at, well, macro expansion time which gives a minimal performance increase. The main reason is that Also that's a mischaracterization, what happens is that one small package is loaded in order to avoid having to load all those other, potentially huge, packages upfront.
That's because nobody realized the consequence of your supposed fix: it results in customization to
That's because this time around someone noted what the consequences of what you are proposing would be. If you really really want to avoid having to load
or
|
Jonas Bernoulli notifications@github.com writes: OK, I understand and accept your reasoning. That all seems perfectly Thanks for taking the trouble to engage with me on this. I hope I Phil Hudson http://hudson-it.ddns.net |
I personally would prefer if use-package were not necessary at runtime, unless you wanted to autoload it for commands like |
Actually we can have both using |
Jonas Bernoulli notifications@github.com writes:
Best of both worlds. A happy result, since the defaults seem sensible Phil Hudson http://hudson-it.ddns.net |
In the macro `use-package-with-elapased-timer' use `bound-and-true-p' go get the values of the customizable options `use-package-verbose' and `use-package-minimum-reported-time'. This way the library only has to be required at compile time, provided these options are not actually customized. If the user has changed the values, then she also has to load the library at runtime or the macros fall back to the default of doing their job silently. See jwiegley/use-package#149.
In the macro `use-package-with-elapased-timer' use `bound-and-true-p' go get the values of the customizable options `use-package-verbose' and `use-package-minimum-reported-time'. This way the library only has to be required at compile time, provided these options are not actually customized. If the user has changed the values, then she also has to load the library at runtime or the macros fall back to the default of doing their job silently. See jwiegley/use-package#149.
See issues #13 and #17 -- it's happened again, culprit this time is
use-package-verbose
. Effect is that you have to(require use-package)
at runtime or you get a void-variable error. As before, the fix will be to ensure the variable (user option) is eval'ed at code-planting time rather than at runtime.The text was updated successfully, but these errors were encountered: