Proposal: Add --with-libedit flag to the readline package

Judah Jacobson judah.jacobson at
Sat Jan 12 16:04:16 EST 2008

On 1/12/08, Yitzchak Gale <gale at> wrote:
> Judah Jacobson wrote:
> > OK, you both have convinced me.  I'll get to work on an editline
> > library.
> Excellent!
> > - To start with, provide one module, System.Console.Editline.Readline.
> >  That module will be mostly a cut-and-paste of all the functions from
> > System.Console.Readline which are supported by editline (version 5.1,
> > as distributed on OS X 10.4).
> > - In the future, we can provide System.Console.Editline which provides
> > the non-readline APIs.
> I would prefer if you call it System.Console.Editline to begin with,
> even if it doesn't support the full API yet, so we can already
> start migrating our code.
> If you want, you can also include System.Console.Editline.Readline
> to provide some Readline-compatible wrappers for the new API
> where possible. That might help some people with backward
> compatibility. But for me that is a lower priority.

I think you may have misunderstood me; let me clarify what I said above.

The editline library itself provides two C interfaces:
1. <histedit.h>, the native editline interface
2. <readline/readline.h>, a subset of the APIs from GNU readline.

These two interfaces do not overlap, as far as I can tell (although #2
is built on top of #1).  I was proposing that they correspond to the
1. System.Console.Editline
2. System.Console.Editline.Readline

For now, I'm only working on #2, since it'll be easier to integrate
with ghci, and the code for the bindings will be nearly identical to
System.Console.Readline from the readline package.  But #1 would
obviously be useful to have too, and we can add it at a later date.

Does that address your concerns?


More information about the Libraries mailing list