Closed jingchengx closed 10 months ago
This kind of error indicates a macro-expansion failure, which usually indicates an installation problem.
However, in this case, you may be encountering a problem which I have sometimes seen and don't yet fully understand.
If it ever happens to me, I'm able to solve it by re-evaluating the hammy-define
form.
It may also be possible that adding :init (hammy-mode)
to the use-package
form solves the problem; I can't recall seeing it since I added that. Of course, that would be a side-effect of that change; AFAICT the solution is to ensure that the hammy-define
macro is loaded before the hammy-define
form is expanded inside the use-package
form. And AFAIK the code in the :config
section should only be evaluated after the package is loaded, which should take care of that. However, some of the code gets wrapped in lambdas, which might affect the expansion. So you might also be able to solve it with :demand t
added to the use-package
form.
Thanks! I've tried the following but none of them is working so far:
:demand t
:init (hammy-mode)
hammy-define
formI suspect it is caused by native compilation, but have no time to dig further for now. Thanks again for the help.
Native compilation shouldn't have anything to do with it, because macro expansion happens at an earlier stage of compilation. Anyway, if you ever figure it out, please let me know. Thanks.
I'm encountering a weird bug: the error message in the title appears whenever the hammy is supposed to advance.
Minimal reproducible example: With the following
init.el
, doM-x hammy-start RET test RET
, wait for 3 seconds and the error message will appear.However if the
:config
portion is removed in theinit.el
and I manually eval(hammy-define ...)
then there is no error. Also the predefined hammies work fine always.init.el
:report-emacs-bug: