emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Emacs <-> Lua bridge


From: michael schuldt
Subject: Re: Emacs <-> Lua bridge
Date: Sun, 18 Apr 2021 13:16:15 -0700

Awesome!

Several years ago I compiled the Lua interpreter into Emacs and added functions for accessing each from the other.
It was just fun experimental software and is not supported or actively developed and still has unresolved issues,
but might be of interest to you. This was before modules got added to Emacs.
You can check out the code here: https://github.com/mschuldt/luamacs


On Sat, Apr 17, 2021 at 9:46 PM Eduardo Ochs <eduardoochs@gmail.com> wrote:
Ooops, I forgot the link to the version with my comments
and instructions to compile on Debian! Here it is:
  http://angg.twu.net/emacs-lua/emlua.cpp.html
  http://angg.twu.net/emacs-lua/emlua.cpp

Cheers =/,
  Eduardo

On Sun, 18 Apr 2021 at 01:32, Eduardo Ochs <eduardoochs@gmail.com> wrote:
>
> Hi list,
>
> about a month ago I asked on the Lua mailing list if anyone there had
> tried to create an Emacs module that would load Lua and then start a
> Lua interpreter and let Emacs call it...
>
> I received this answer,
>
>   http://lua-users.org/lists/lua-l/2021-03/msg00084.html
>
> and today I finally had time to compile that code on Debian and test
> it. It looks prototype-ishy, but it is surprisingly functional - if we
> run something that returns several values, like the second sexp here,
>
>   (emlua-dostring "a = 22")
>   (emlua-dostring "return a+33, '44', {}")
>
> it retuns a vector like this,
>
>   ["55" "44" "table: 0x55f5e0a15a10"]
>
> with tostring-ed versions of all its return values, and if we run
> something that yields an error it returns a string with Lua's error
> message.
>
> I haven't played much with it yet.
> Happy hacking =),
>
>   Eduardo Ochs
>   http://angg.twu.net/#eev
>   http://angg.twu.net/emacsconf2020.html


reply via email to

[Prev in Thread] Current Thread [Next in Thread]