Hello there, Quick Intro: We have an interactive CLI for a language called M used in banking and healthcare... I am working on adding readline integration as a nice to have feature. We are an open source project located over here: https://gitlab.com/YottaDB/DB/YDB.
One thing we have in our previous CLI interpreter is the ability to select a line for editing by position and have it re-display and put the cursor at the end. It works like this: 1. foo 2. boo >rec 2 >boo<cursor> I tried to use rl_replace_line(h->line, 1) (h is the history item), then rl_redisplay(), but nothing show up. I looked hard on Github to see if there is any example of this, but not really finding anything. Hope somebody has an idea of how to do it, or if it is not possible at all, or if it is possible but my code isn't working (in which case I will try to come up with a standalone example). I am developing against v7.0-150400.25.22 packaged with SUSE Linux Enterprise Desktop 15 SP4, but my code will run with whatever version gets dlopen()'ed. --Sam
