[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Chicken-users] compiled program + REPL ?
From: |
Christian Kellermann |
Subject: |
Re: [Chicken-users] compiled program + REPL ? |
Date: |
Tue, 25 Oct 2016 09:38:37 +0200 |
User-agent: |
Mutt/1.5.24 (2015-08-30) |
* founda happyplace <address@hidden> [161024 21:54]:
> Hi Chicken Friends!
>
> What is possible in terms of connecting to a REPL supplied by a running
> compiled Chicken program? Is it one of the below?
>
> --1-- It's the same as any compiled C program, there's no REPL to connect
> to. Once you've compiled to an executable, you've exited lisp-land. But at
> least you enjoyed your visit.
>
> --2-- There's an egg for it. Your program could include this egg to support
> a connection. From there you could inspect, evaluate, redefine things to
> affect the running program. Once your program is restarted, your changes
> are gone. It's your original program that gets started.
>
> --3-- There's no such egg like [2] but it's possible.
>
> --4-- You can connect, make changes, and save the instance as something new
> on the machine that's running your original program. It won't be as fast as
> your original compiled output but at least this new thing can be restarted
> in the state you left it; you could run it instead of your original
> program. Perhaps it's your original program that gets started initially,
> and then a REPL session is re-played on top of it to resurrect your
> desired state.
>
> --5-- There's nothing like [4] yet but it's possible.
>
Also there's the -:b runtime option dropping you into (repl) on
error. You can also use (repl) to upen up a -- well repl -- in your
own code.
FWIW I would go with the nrepl egg.
HTH,
Christian
--
May you be peaceful, may you live in safety, may you be free from
suffering, and may you live with ease.