]>
Commit | Line | Data |
---|---|---|
13bba25e AF |
1 | --- pl-3.4.2/src/pl-rl.c.wiget Fri Apr 13 20:15:48 2001 |
2 | +++ pl-3.4.2/src/pl-rl.c Fri Apr 13 20:19:55 2001 | |
3 | @@ -68,7 +68,7 @@ | |
4 | extern int rl_begin_undo_group(void); /* delete when conflict arrises! */ | |
5 | extern int rl_end_undo_group(void); | |
6 | extern Function *rl_event_hook; | |
7 | -extern char *filename_completion_function(char *, int); | |
8 | +extern char *rl_filename_completion_function(const char *, int); | |
9 | ||
10 | ||
11 | static foreign_t | |
12 | @@ -238,8 +238,8 @@ | |
13 | ||
14 | ||
15 | static char * | |
16 | -atom_generator(char *prefix, int state) | |
17 | -{ char *s = PL_atom_generator(prefix, state); | |
18 | +atom_generator(const char *prefix, int state) | |
19 | +{ char *s = PL_atom_generator((char *)prefix, state); | |
20 | ||
21 | if ( s ) | |
22 | return strcpy(xmalloc(1 + strlen(s)), s); | |
23 | @@ -249,17 +249,17 @@ | |
24 | ||
25 | ||
26 | static char ** | |
27 | -prolog_completion(char *text, int start, int end) | |
28 | +prolog_completion(const char *text, int start, int end) | |
29 | { char **matches = NULL; | |
30 | ||
31 | if ( (start == 1 && rl_line_buffer[0] == '[') ) /* [file */ | |
32 | - matches = completion_matches(text, | |
33 | - (void *) filename_completion_function); | |
34 | + matches = rl_completion_matches(text, | |
35 | + (void *) rl_filename_completion_function); | |
36 | else if (start == 2 && strncmp(rl_line_buffer, "['", 2)) | |
37 | - matches = completion_matches(text, | |
38 | - (void *) filename_completion_function); | |
39 | + matches = rl_completion_matches(text, | |
40 | + (void *) rl_filename_completion_function); | |
41 | else | |
42 | - matches = completion_matches(text, atom_generator); | |
43 | + matches = rl_completion_matches(text, atom_generator); | |
44 | ||
45 | return matches; | |
46 | } |