[Top][All Lists]

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

Clear prompt in readline?

From: Jan Wielemaker
Subject: Clear prompt in readline?
Date: 11 Oct 2001 10:25:57 GMT
User-agent: slrn/ (Linux)


I'm using the readline library (part of bash, which is why I post here).
Works great, but I notice that after

        line = readline("?- ");

(or any other non-empty string), there is no way to get rid of the
prompt. Both after readline("") and readline(NULL) it still prompts me
with "?- ". From the source, I see calling rl_set_prompt() is the same
as this is called right away from readline(). The prompt logic is a bit
too complicated to track it down easily for me.

I guess this is a bug.  It could be argued that readline(NULL) keeps
the current prompt, but readline("")??

Anyone to confirm?  Is there an easy hack around?  I would be glad if
my software (SWI-Prolog) runs with existing readline shared objects.

        Thanks --- Jan

reply via email to

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