3 ms·
Interesting. Is there any language you or the sibling have used that does this with eval, and does it find much use?
by hyperpape 10y ago
Interesting. Is there any language you or the sibling have used that does this with eval, and does it find much use?
- BuuQu9hu 10y agoE and Monte have safe eval() as a consequence of being object-based capability-safe languages; there's no way to cause any effect outside eval() worse than an infinite loop. To the second part of your question: as you have undoubtedly noticed, you've never heard of E nor Monte.
- hyperpape 10y agoFunny that you say that. When I sat down at my machine at work, one of the 100 or so chrome tabs I had open was a page about The Vat: http://www.erights.org/elib/concurrency/vat.html http://www.erights.org/elib/concurrency/vat.html.
- BuuQu9hu 10y agoWe have vat documentation too: http://monte.readthedocs.io/en/latest/vats.html http://monte.readthedocs.io/en/latest/vats.html
- shakna 10y agoSure! Most of the time, it just makes it easier to parse and interpret input in a safe manner. * Racket [0], sometimes used when you don't want to use Racket's way of designing DSLs, or if you want to interface to databases simpler. * Scheme [1], used when designing DSLs, interacting with databases. You often see it go hand-in-hand with X-Expressions. * Lua [2] can, but it is rarely used. Note, the link for Lua actually lists a whole host of languages where this can be technically done, but not all are entirely safe. I think it's uncommonality is not because of it's inconvenience or rarity, but rather the mantra of 'eval is evil' in the programming community, even when it doesn't apply. [0] https://docs.racket-lang.org/guide/eval.html https://docs.racket-lang.org/guide/eval.html [1] https://www.gnu.org/software/guile/manual/html_node/Environments.html https://www.gnu.org/software/guile/manual/html_node/Environm... [2] https://rosettacode.org/wiki/Runtime_evaluation/In_an_environment#Lua https://rosettacode.org/wiki/Runtime_evaluation/In_an_enviro...