[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: How to create interactive mode for Java Swing application using Lua Java?
- From: Jonas Bengtsson <jonas.b@...>
- Date: Wed, 15 Nov 2006 22:58:26 +0000
Sam Roberts wrote:
It does have the "=" shortcut:
> = 1 + 4
> = (function() return"hello world" end)()
= is just replaced with "return "
I didn't know that one, cool!
Also, a trick I learned from somewhere in the source and use in my
interactive consoles - I prepend "return " to any code before loading
it. If it fails to compile because of a syntax error, I try again
without the return.
I finally came around to try this one out today and it worked like a
charm. It's a neat hack, thanks!