Issue 6877: this patch makes it possible to link the readline extension
to the libedit emulation of the readline API on OSX 10.5 or later.

This also adds a minimal testsuite for readline to check that the
history manipuation functions have the same interface with both
C libraries.
diff --git a/Doc/library/readline.rst b/Doc/library/readline.rst
index 685b36f..89addaa 100644
--- a/Doc/library/readline.rst
+++ b/Doc/library/readline.rst
@@ -14,6 +14,17 @@
 interactive prompt  and the prompts offered by the :func:`raw_input` and
 :func:`input` built-in functions.
 
+..note::
+
+  On MacOS X the :mod:`readline` module can be implemented using
+  the ``libedit`` library instead of GNU readline.
+
+  The configuration file for ``libedit`` is different from that
+  of GNU readline. If you programmaticly load configuration strings
+  you can check for the text "libedit" in :const:`readline.__doc__`
+  to differentiate between GNU readline and libedit.
+
+
 The :mod:`readline` module defines the following functions:
 
 
@@ -181,7 +192,6 @@
 
    Append a line to the history buffer, as if it was the last line typed.
 
-
 .. seealso::
 
    Module :mod:`rlcompleter`