On 2016-05-28 15:07, Stefan Monnier wrote: >> ;;;###autoload >> (defconst realgud-content-dir >> (file-name-directory >> (or (and load-in-progress load-file-name) >> (bound-and-true-p byte-compile-current-file) >> buffer-file-name))) > > Why do you need to check load-in-progress? The docs of load-file-name don't say what this variable becomes when outside of load. It is always nil when load-in-progress is nil? > And why do you need to fallback on byte-compile-current-file or > buffer-file-name? I'd like this code to work when the form is evaluated with C-M-x in an Emacs buffer. Since this isn't in an eval-when-compile form, though, I guess it would work to remove the byte-compile-current-file part. Thanks! Clément.