RFC: IPerl - Interactive Perl ( read-eval-print loop )by mseabrook (Beadle)
|on Feb 03, 2007 at 01:54 UTC||Need Help??|
I've put together a simple script (module, really) that implements a REPL for perl. I'm sure most are familiar with the term, but for those that aren't, the idea is that the script reads an expression from the user, evaluates the expression, and finally, prints the result. The script then repeats the process.
Some trivial examples:
I've found it to be invaluable for testing small snippits of code, calling methods in package modules, and benchmarking subroutines and module load times.
I'm considering submitting this to CPAN but I'm hesitating. I'm hesitating because I haven't seen anything like it there and it's the sort of thing that a lot of programming languages either ship with, or acquire quickly (examples: ruby, python, haskell), so I feel like there should already be an implementation (or six) out there that everyone's using.
Anyways, if you fine folks think this will be useful, I'd love to hear your suggestions on how to improve the interface and the implementation. I haven't packaged up the source code into an easily digestable tarball yet, but the POD documentation is available here.
On the other hand, if I'm re-inventing a wheel, please direct me to the original prototype. I'm sure it rolls better. :)
BTW, this is my first post. I apologize if it's in the wrong section or is generally un-monklike.