[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: use-package.el -> Emacs core

From: João Távora
Subject: Re: use-package.el -> Emacs core
Date: Tue, 10 Nov 2015 21:00:53 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (darwin)

John Wiegley <address@hidden> writes:

>>    (package-install 'markdown-mode)
>>    (with-eval-after-load 'markdown-mode
>>      (modify-syntax-entry ?` "\"" markdown-mode-syntax-table))
> To match those semantics, you'd use:
>     (use-package markdown-mode
>       :ensure t
>       :config (modify-syntax-entry ?` "\"" markdown-mode-syntax-table))

OK, so we would agree that in this particular example it doesn't bring a
great advantage, if any. Perhaps you could provide another example where
you definitely think it does.

>> I don't think you understood. I don't mean bugs in `use-package', I mean bug
>> reports in my extensions that are reported in terms of `use-package'. Should
>> I not handle those bugs?
> Ah. Does it help that you can macro-expand use-package forms, so that you see
> what the underlying Emacs Lisp calls? I try hard to make the expanded code
> "look like what you'd write", as much as possible.

That's what I would do yes. But then I have to have a running emacs with
`use-package' myself, right? I've seen some macroexpansions of it
somewhere in this thread and it's not particularly pretty (also not
particularly correct apparently: see my criticism of the use of fboundp
and autoload, for example).

But I can't resist pointing out a certain irony in your argument: if
use-package is not hiding any ugly implementation details, there's
really no use for it :-).

For contrast, and quite a scare, see the macroexpansions of
`define-minor-mode` or `define-globalized-minor-mode'. yucky.

On the other hand, I have to admit that by participanting in this
discussion I ended up probably learning more than enough of the
use-package minilanguage to handle such a bug report.

So I don't know. Count me in the "initially against, but now doesn't
care" category and let the masses decide :-)


reply via email to

[Prev in Thread] Current Thread [Next in Thread]