5
How to make a REPL-based DSL using rust
(sh.itjust.works)
Clap has an entry in their cookbook for a REPL:
Of course, this works best for simple stuff, where you just have individual commands to parse.
For a Python-style REPL with a full-fledged language attached, I would not use that approach.
There's probably some REPL languages implemented in Rust already out there, where you can look at their approach.
Welcome to the Rust community! This is a place to discuss about the Rust programming language.
Credits