3 ms·
A SLIME* for Python, Perl or Ruby (http://common-lisp.net/project/slime/ http://common-lisp.net/project/slime/). All of these languages have a powerful reflect
by strlen 18y ago
A SLIME* for Python, Perl or Ruby (http://common-lisp.net/project/slime/ http://common-lisp.net/project/slime/).
All of these languages have a powerful reflection/meta programming facility (yes, Perl included). So technically, something like could be implemented:
1) The server (using Twisted in Python or POE in Perl) listens for requests. Requests are for objects.
2) The server looks at the request, serializes it into a s-exp describing the state of the object sent to it.
3) Emacs then looks at the s-exp and decides what to do with the object initially looked at (suggest a method to complete/use on? highlights it red if it's wrong? bring up HTML formated documentation, etc...)
- apgwoz 18y ago> SLIME* for Python, Perl or Ruby I'm not entirely sure, but I think you might just have to implement a Swank server, and SLIME* would work without problems. It could be that you're forced to use s-expressions, but I doubt it.
- strlen 18y agoI haven't looked at the client portion of SLIME in a while, but wouldn't there be some changes needed to deal with languages where statements and expression are different from each other? Getting Perl code into an s-exp would be fairly difficult actually (as opposed to getting an s-exp from a Perl complex hash -- which would be really easily) - generally (with Perl5) the consensus is anything that can parse Perl, is Perl. Python, Ruby and Perl6 (which effectively is a Lisp, complete with macros in forms of first-order primitives for CFGs) would, I am sure, be easier a lot easier.
- apgwoz 18y ago> I haven't looked at the client portion of SLIME in a while, but wouldn't there be some changes needed to deal with languages where statements and expression are different from each other? Yeah, probably.
- almost 18y agoYou might want to look into ropemacs (and pymacs which it uses) for some slimeish stuff with python in Emacs. I way to go from there to slime but it's a start.