5

How can eval-when-compile and eval-and-compile have different behavior if their definitions are identical? The hint is in the commentary in the definition of eval-and-compile: ;; When the byte-compiler expands code, this macro is not used, so we're ;; either about to run `body' (plain interpretation) or we're doing eager ;; macroexpansion. Indeed, it's not ...


4

I found a way to do it interactively with el-search (http://elpa.gnu.org/packages/el-search.html). M-x el-search `(,(pred macrop) ,_) finds them. Interestingly, it matches backticked s-exps like `(:annotation-function ,type-annotation) too. Here is an interactive function version: (defun find-macro-calls-1 () (interactive) (goto-char (point-min)) (el-...


3

Node Warning Tips of the Elisp manual tells us: • To avoid a compiler warning about an undefined function that you know will be defined, use a declare-function statement (see Declaring Functions). • If you use many functions, macros, and variables from a certain file, you can add a require (see require: Named Features) for that package to avoid compilation ...


2

After submitting a bug report for this that was rejected I better understand the overall intent of the byte compiler as it was best described by Lars Ingebrigtsen in his closing remark: "The issue isn't that the compiler warning is wrong -- it's correct; but we suppress it in very particular situations where it'll obviously not lead to any problems.&...


1

Your code is missing a (require 'use-package); without that, Emacs gets confused about use-package and treats it as a function instead of a macro.


Only top voted, non community-wiki answers of a minimum length are eligible