[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: RE: C# and Lua
- From: Sean Middleditch <elanthis@...>
- Date: 06 Jan 2003 12:48:27 -0500
It really shouldn't be much different than writing Lua in C, no? I
mean, you could have a .NET type/class for a "Lua Value", which used the
native String/int/float/array/etc. types where appropriate. It could
allow dynamic changing - assign an array type to the type (value.assign
(array)) and the class stores the array and marks itself as an array
type. Assing a string to the same variable/member/etc. (value.assign
("a string"))) and it would store the string, and mark itself as a
The method could be overloaded to react differently based on the type.
For example the + operator could look at the types involved - if
strings, do concatenation; if numbers, just add; if tables, call a
method in the table, and so on.
It won't be able to optimize as well (for example, know to just call
string concatenation at compile time, versus having to check types on
run-time) but it would still work, I would think.
Or am I missing some important fact here? (as usual) ^,^
On Mon, 2003-01-06 at 12:19, MichaelL@frogware.com wrote:
> As far as I know, there's been little success implementing scripting
> languages in .NET. The problem is that most scripting languages are
> dynamically typed, and the .NET Runtime is statically typed. The
> Python.NET guys experimented with a variety of approaches--such as
> emiting code on the fly--but none worked very well. (I don't know the
> current status of Python.NET.)
> Of course, it's still possible to implement an interpreter on top of
> .NET, and write glue between the two layers. That, however, isn't
> quite the same as producing Lua.NET--which has JIT-compiled code,
> debugging support, etc.
> "John Passaniti"
> Sent by:
> 01/05/2003 10:55 PM
> Please respond to lua-l
> Multiple recipients of
> RE: C# and Lua
> While I can't comment on using the C# interop mechanisms to work with
> C-language Lua, I was very interested to read this:
> > PS: I'm aware of the fact, that there'll be a
> > Lua.NET down the road (I've seen the project
> > page), but I need Lua now ... not in (many?)
> > months.
> It's probably old news for others here, but I never saw any sort of
> announcement that a Lua.NET was in the works. So I looked in Google
> found this:
> Which also leads to this:
> I look forward to a Lua.NET. I especially look forward to a Lua
> in C#. Interesting that Microsoft Research is sponsoring this.
Sean Middleditch <email@example.com>
AwesomePlay Productions, Inc.