-
Notifications
You must be signed in to change notification settings - Fork 260
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
void variable error while using byte-compiled init files #436
Comments
|
Try adding In uncompiled code, using the |
|
Oops. I am stupid.
I forgot to add (require 'use-package) to my .emacs file (which is the
first one to be loaded).
After adding that line before loading other init files, everything
works!
You made my day! Thanks! :-D
P.S. Question will be closed.
Danny
…On 2017-03-12 16:01, Noam Postavsky ***@***.***> wrote:
Try adding `(require 'bind-key)` to your init file.
In uncompiled code, using the `use-package` macro will autoload `use-package` which also loads `bind-key`. But when you compile, the expansion of the macro doesn't need to load `use-package`, so it never gets loaded. Perhaps the `use-package` macro should add `(require 'bind-key)` to its expansion?
|
|
Adding "(require 'use-package)" before loading other init files solved the problem. |
Hi,
I was trying to changing my init files into use-package forms, and everything was fine.
Then I was thinking of speeding up the loading process by byte compiling every file under "~/.emacs.d/settings" directory (the directory I place all the init files), so I did.
However I got a problem while loading some .elc file, "emacs --debug-init" gives:
This is strange because if I load .el instead of .elc then everything works.
Also if I use the old require-and-define-key way instead of use-package, the problem disappears.
I am using snippet below to automatically load my file:
Code snippet that causes the problem:
This problem only appears iff both use-package and byte compiled init files are used.
Any idea?
The text was updated successfully, but these errors were encountered: