summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2022-10-26 23:16:09 (GMT)
committerGitHub <noreply@github.com>2022-10-26 23:16:09 (GMT)
commit75990a56b7f5545b7673972881c2769586742f69 (patch)
treef8f254e77312bed0720aa595c101c07036440017
parent3bad567d085e5380fd6c4309e44aee7b8ee4ea36 (diff)
downloadcpython-75990a56b7f5545b7673972881c2769586742f69.zip
cpython-75990a56b7f5545b7673972881c2769586742f69.tar.gz
cpython-75990a56b7f5545b7673972881c2769586742f69.tar.bz2
Fix readline.c compiler warning. (GH-98738)
``` Modules/readline.c:1260:37: warning: assigning to 'char *' from 'const char *' discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers] completer_word_break_characters = ^ ``` (cherry picked from commit 29b391b1378577825a658b14764a8ff3e0b5c958) Co-authored-by: Benjamin Peterson <benjamin@python.org>
-rw-r--r--Modules/readline.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/readline.c b/Modules/readline.c
index 1b616fc..27b89de 100644
--- a/Modules/readline.c
+++ b/Modules/readline.c
@@ -1258,9 +1258,9 @@ setup_readline(readlinestate *mod_state)
rl_attempted_completion_function = flex_complete;
/* Set Python word break characters */
completer_word_break_characters =
- rl_completer_word_break_characters =
strdup(" \t\n`~!@#$%^&*()-=+[{]}\\|;:'\",<>/?");
/* All nonalphanums except '.' */
+ rl_completer_word_break_characters = completer_word_break_characters;
mod_state->begidx = PyLong_FromLong(0L);
mod_state->endidx = PyLong_FromLong(0L);