
Helmut Eller <e9626484@stud3.tuwien.ac.at> writes:
Alan Ruttenberg <alanralanr@comcast.net> writes:
One might argue that evaluating or loading a compiled expression inside an emacs buffer visiting a file should be as close as possible to what happens when the file is loading.
Do you need this often?
This is a bit too DWIMish for my taste and I think slime-load-file should be used in such situations.
I'm not so sure: we already DWIM as far as setting *package* from the file's package is concerned, and I don't think anyone's going to argue that that's a bad thing: is it so much more wrong to set *compile-file-pathname*? I often write code that accesses files in the same directory as the source (or a directory with a fixed relation to the source code). Because I always use systems to load code, *default-pathname-defaults* is not necessarily the right place, so I like to use *load-pathname* to get the right place. This doesn't currently work if I C-c C-c the relevant form. (There's also a possibility that setting *cfp* during function compilation makes the implementation remember where the function came from such that M-. is more likely to continue working afterwards. That depends on the implementation, obviously.) -dan -- http://web.metacircles.com/ - Open Source software development and support