summaryrefslogtreecommitdiffstats
path: root/Modules/readline.c
Commit message (Collapse)AuthorAgeFilesLines
* PyThreadState_Swap(NULL) didn't do what I thought it did. FixesMichael W. Hudson2004-07-081-1/+1
| | | | [ 987287 ] Python 2.4a1, interpreter hanging on Keyboard Interrupt
* This closes patch:Michael W. Hudson2004-07-071-8/+89
| | | | | | | | | | | | | | | | | [ 960406 ] unblock signals in threads although the changes do not correspond exactly to any patch attached to that report. Non-main threads no longer have all signals masked. A different interface to readline is used. The handling of signals inside calls to PyOS_Readline is now rather different. These changes are all a bit scary! Review and cross-platform testing much appreciated.
* stupid, stupid, stupid... raw_input() already supports readline() if theSkip Montanaro2004-05-241-23/+0
| | | | readline module is loaded.
* Exposed readline() function from the readline module.Skip Montanaro2004-05-231-0/+23
|
* A few more PyThreadState_Get to PyThreadState_GET conversionsNicholas Bastin2004-03-251-1/+1
|
* remove support for missing ANSI C header files (limits.h, stddef.h, etc).Skip Montanaro2004-02-101-1/+1
|
* Patch #804543: strdup saved locales. Backported to 2.3.Martin v. Löwis2003-11-131-1/+2
|
* Patch #800697: Add readline.clear_history.Martin v. Löwis2003-09-201-0/+21
|
* Remove inaccurate (and it turns out, entirely superfluous) declarations ofMichael W. Hudson2003-07-171-4/+0
| | | | | | PyOS_InputHook and PyOS_ReadlineFunctionPointer). The inaccuracies were causing problems in framework builds on Mac OS X.
* Use appropriate macros not the deprecated DL_IMPORT/DL_EXPORT macrosNeal Norwitz2003-07-011-2/+2
|
* get_completer() takes no argsNeal Norwitz2003-03-011-1/+1
|
* flex_complete looks like a private (but callback) function, so make it staticNeal Norwitz2003-02-211-1/+1
|
* I was in this module anyway, so I did some janitorial things.Michael W. Hudson2003-01-301-17/+14
| | | | | | | | METH_NOARGS functions are still called with two arguments, one NULL, so put that back into the function definitions (I didn't know this until recently). Make get_history_length() METH_NOARGS.
* Add the get_completer() function based on Michael Stone's patch inMichael W. Hudson2003-01-301-0/+17
| | | | | | [ 676342 ] after using pdb readline does not work correctly which is required to fix that bug. So maaybe a bugfix candidate.
* Fix from Michael Stone for SF bug #660476 and #513033 (bogus threadGuido van Rossum2003-01-071-13/+7
| | | | state swaps in readline).
* A few more whitespace normalizations.Guido van Rossum2003-01-071-1/+4
|
* Various cleanups:Guido van Rossum2003-01-071-45/+80
| | | | | | | | - Whitespace normalization. - Cleaned up some comments. - Broke long lines.
* Patch 659834 by Magnus Lie Hetland:Guido van Rossum2002-12-301-0/+4
| | | | | | | | | Check for readline 2.2 features. This should make it possible to compile readline.c again with GNU readline versions 2.0 or 2.1; this ability was removed in readline.c rev. 2.49. Apparently the older versions are still in widespread deployment on older Solaris installations. With an older readline, completion behavior is subtly different (a space is always added).
* Patch #512981: Update readline input stream on sys.stdin/out change.Martin v. Löwis2002-10-261-7/+13
|
* GNU readline() mistakenly sets the LC_CTYPE locale.Guido van Rossum2002-10-091-0/+17
| | | | | This is evil. Only the user or the app's main() should do this! We must save and restore the locale around the rl_initialize() call.
* Excise DL_EXPORT/DL_IMPORT from Modules/*. Required adding a prototypeMark Hammond2002-08-021-1/+1
| | | | | | for Py_Main(). Thanks to Kalle Svensson and Skip Montanaro for the patches.
* Patch #568124: Add doc string macros.Martin v. Löwis2002-06-131-73/+59
|
* patch #562492 - prevent duplicate lines in historySkip Montanaro2002-06-111-2/+19
| | | | also call using_history() to properly initialize history variables
* SF #558432: Prevent Annoying ' ' from readline (Holker Krekel).Guido van Rossum2002-05-301-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | readline in all python versions is configured to append a 'space' character for a successful completion. But for almost all python expressions 'space' is not wanted (see coding conventions PEP 8). For example if you have a function 'longfunction' and you type 'longf<TAB>' you get 'longfunction ' as a completion. note the unwanted space at the end. The patch fixes this behaviour by setting readline's append_character to '\0' which means don't append anything. This doesn't work with readline < 2.1 (AFAIK nowadays readline2.2 is in good use). An alternative approach would be to make the append_character accessable from python so that modules like the rlcompleter.py can set it to '\0'. [Ed.: I think expecting readline >= 2.2 is fine. If a completer wants another character they can append that to the keyword in the list.]
* #544265, Remove warnings for passing const to free()Neal Norwitz2002-04-211-1/+1
|
* Get rid of warnings due to changing to METH_NOARGSNeal Norwitz2002-03-311-5/+5
|
* Remove many uses of PyArg_NoArgs macro, change METH_OLDARGS to METH_NOARGS.Neal Norwitz2002-03-251-23/+10
|
* Add get_history_item, get_current_history_length, and redisplay functions.Neil Schemenauer2002-03-241-2/+61
| | | | Clarify the docstring for get_history_length. Closes SF patch 494066.
* OS/2 EMX port changes (Modules part of patch #450267):Andrew MacIntyre2002-03-031-0/+4
| | | | | | | | | | | | | | | Modules/ _hotshot.c dbmmodule.c fcntlmodule.c main.c pwdmodule.c readline.c selectmodule.c signalmodule.c termios.c timemodule.c unicodedata.c
* Simon Budig's patch (posted by me):Michael W. Hudson2002-02-131-0/+3
| | | | [ #513235 ] prevent readline filename completion
* Include <unistd.h> in Python.h. Fixes #500924.Martin v. Löwis2002-01-121-4/+0
|
* sprintf -> PyOS_snprintf in some "obviously safe" cases.Tim Peters2001-11-281-2/+4
| | | | | Also changed <>-style #includes to ""-style in some places where the former didn't make sense.
* Fixes for possible buffer overflows in sprintf() usages.Marc-André Lemburg2001-11-281-2/+2
|
* SF patch #443759: Add Interface to readline's add_historyGuido van Rossum2001-10-191-0/+18
| | | | | | | | | | | | | | This was submitted by Moshe, but apparently he's too busy to check it in himself. He wrote: Here is a function in GNU readline called add_history, which is used to manage the history list. Though Python uses this function internally, it does not expose it to the Python programmer. This patch adds direct interface to this function with documentation. This could be used by friendly modules to "seed" the history with commands.
* Patch #462122: add readline startup and pre_event hooks.Martin v. Löwis2001-09-301-24/+127
|
* Cleaned up the docstring for readline.set_completer().Fred Drake2001-08-011-1/+1
| | | | Thanks to Nathaniel Gray for reporting the confusion.
* SF Patch #432457 by Jason Tishler: support for readline 4.2.Guido van Rossum2001-07-101-0/+4
| | | | | | | This patch allows the readline module to build cleanly with GNU readline 4.2 without breaking the build for earlier GNU readline versions. The configure script checks for the presence of rl_completion_matches in libreadline.
* Clean up the unsightly mess around the readline header files. We nowGuido van Rossum2001-04-131-24/+1
| | | | | | | | | | | | | | | | | | | | | | | always: - #undef HAVE_CONFIG_H (because otherwise chardefs.h tries to include strings.h) - #include readline.h and history.h and we never declare any readline function prototypes ourselves. This makes it compile with readline 4.2, albeit with a few warnings. Some of the remaining warnings are about completion_matches(), which is renamed to rl_completion_matches(). I've tested it with various other versions, from 2.0 up, and they all seem to work (some with warnings) -- but only on Red Hat Linux 6.2. Fixing the warnings for readline 4.2 would break compatibility with 3.0 (and maybe even earlier versions), and readline doesn't seem to have a way to test for its version at compile time, so I'd rather leave the warnings in than break compilation with older versions.
* Part of SF patch #102409 by jlt63 to support building these modulesGuido van Rossum2001-01-101-2/+6
| | | | under CYGWIN as shared libraries (DLLs).
* Supporting rl_library_version is more trouble than it's worth --Guido van Rossum2000-10-021-8/+1
| | | | | | | readline doesn't have it before readline 2.2 and there's no compile-time way to find out which readline version is in use. Sigh. GNU readline sucks.
* Add a definition of rl_library_version. Reported by jpettit@sourceforge.Guido van Rossum2000-09-201-0/+1
|
* Use PyOS_setsig() instead of directly calling signal() or sigaction().Guido van Rossum2000-09-161-5/+12
| | | | | | | This fixes the first half of bug #110611: the immediate exit when ^C is hit when readline and threads are configured. Also added a new module variable, readline.library_version.
* Add three prototypes for functions in history.h to shut up gcc -Wall.Guido van Rossum2000-09-011-0/+3
|
* Peter Schneider-Kamp <nowonder@nowonder.de>:Fred Drake2000-08-311-7/+7
| | | | | | Remove some of GCC's warning in -Wstrict-prototypes mode. This closes SourceForge patch #101342.
* Removed unnecessary local variable -- gave warning on gcc -WallMoshe Zadka2000-08-041-2/+0
|
* Use METH_OLDARGS instead of numeric constant 0 in method def. tablesAndrew M. Kuchling2000-08-031-7/+8
|
* Use METH_VARARGS instead of numeric constant 1 in method def. tablesAndrew M. Kuchling2000-08-031-8/+12
|
* Removed all instances of RETSIGTYPE from the source code: signalTim Peters2000-07-231-5/+2
| | | | | | | handlers "return void", according to ANSI C. Removed the new Py_RETURN_FROM_SIGNAL_HANDLER macro. Left RETSIGTYPE in the config stuff, because it's not clear to me that others aren't relying on it (e.g., extension modules).
* ANSIfication of function-pointers and declarations. Also, make sure toThomas Wouters2000-07-221-2/+5
| | | | | return something if RETSIGTYPE is not void, in functions that are defined as returning RETSIGTYPE.
* Bunch of minor ANSIfications: 'void initfunc()' -> 'void initfunc(void)',Thomas Wouters2000-07-211-2/+2
| | | | | | | | | | | | | | | | | | and a couple of functions that were missed in the previous batches. Not terribly tested, but very carefully scrutinized, three times. All these were found by the little findkrc.py that I posted to python-dev, which means there might be more lurking. Cases such as this: long func(a, b) long a; long b; /* flagword */ { and other cases where the last ; in the argument list isn't followed by a newline and an opening curly bracket. Regexps to catch all are welcome, of course ;)