[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [ELPA] New package: disk-usage
From: |
Stefan Monnier |
Subject: |
Re: [ELPA] New package: disk-usage |
Date: |
Sun, 24 Feb 2019 15:24:04 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) |
> Purcell argues that Stefan should not have used `eval-when-compile' for
> `cl-lib`:
>
> --8<---------------cut here---------------start------------->8---
> (eval-when-compile (require 'cl-lib))
> --8<---------------cut here---------------end--------------->8---
>
> because `cl-first' is used in some places.
>
> I'd tend to agree with Purcell. Thoughts?
If you use #'cl-first then you definitely need to remove the
eval-when-compile, indeed.
But if you have direct calls to cl-first, then they will be compiled
into byte-code which do not refer to `cl-first` any more (IOW the
cl-first definition has been inlined by the compiler).
Hence your code should still work with eval-when-compile.
[ Yes: the exact conditions under which a library can be `require`d
inside `eval-when-compile` can be pretty subtle. ]
I used eval-when-compile because it seemed to work, but feel free to
change it, whether for technical reasons or just out of
personal preference.
Stefan
- Re: [ELPA] New package: disk-usage, (continued)
- Re: [ELPA] New package: disk-usage, Michael Albinus, 2019/02/19
- Re: [ELPA] New package: disk-usage, Pierre Neidhardt, 2019/02/19
- Re: [ELPA] New package: disk-usage, Pierre Neidhardt, 2019/02/19
- Re: [ELPA] New package: disk-usage, Pierre Neidhardt, 2019/02/20
- Re: [ELPA] New package: disk-usage, Stefan Monnier, 2019/02/20
- Re: [ELPA] New package: disk-usage, Pierre Neidhardt, 2019/02/24
- Re: [ELPA] New package: disk-usage, Pierre Neidhardt, 2019/02/24
- Re: [ELPA] New package: disk-usage,
Stefan Monnier <=
- Re: [ELPA] New package: disk-usage, Michael Albinus, 2019/02/26
- Re: [ELPA] New package: disk-usage, Pierre Neidhardt, 2019/02/26
- Re: [ELPA] New package: disk-usage, Michael Albinus, 2019/02/26