mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-21 02:03:03 +00:00
bistromathic: don't require spaces after operators for completion
Currently "(1+<TAB>" does not work as expected, because "+" is not a word breaking character. * examples/c/bistromathic/parse.y (init_readline): Specify our word breaking characters. * examples/c/bistromathic/bistromathic.test: Avoid trailing spaces.
This commit is contained in:
@@ -426,11 +426,15 @@ completion (const char *text, int start, int end)
|
||||
|
||||
void init_readline (void)
|
||||
{
|
||||
/* Allow conditional parsing of the ~/.inputrc file. */
|
||||
rl_readline_name = "pushcalc";
|
||||
// Allow conditional parsing of the ~/.inputrc file.
|
||||
rl_readline_name = "bistromathic";
|
||||
|
||||
/* Tell the completer that we want a crack first. */
|
||||
// Tell the completer that we want a crack first.
|
||||
rl_attempted_completion_function = completion;
|
||||
|
||||
// The basic list of characters that signal a break between words
|
||||
// for the completer routine.
|
||||
rl_basic_word_break_characters = " \t\n\"\\'`@$><=;|&{(+-*/^)";
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user