Actually implement the new procedure code and adapt all of its clients
[pspp-builds.git] / src / language / ChangeLog
1 2007-06-06  Ben Pfaff  <blp@gnu.org>
2
3         * command.def: Add DEBUG DATASHEET command.  Remove DEBUG CASEFILE
4         command.
5
6 2007-03-18  Ben Pfaff  <blp@gnu.org>
7
8         * syntax-string-source.c (close): Rename to do_close to avoid
9         conflict with POSIX function of the same name.
10
11 Thu Feb  8 15:04:42 2007  Ben Pfaff  <blp@gnu.org>
12
13         Reduce platform dependence.
14
15         * command.c (shell): Always define this function, instead of only
16         in unix, but make it a stub when fork or execl is not available.
17         (run_command): Move parsing code into cmd_host.
18         (cmd_host): Drop unix dependence now that the shell function is
19         always defined. 
20
21 Sun Jan 21 15:31:52 WST 2007 John Darrington <john@darrington.wattle.id.au>
22
23         * command.c command.h: Renamed cmd_parse to cmd_parse_in_state.
24         New function cmd_parse.
25
26 Wed Dec 13 21:02:51 2006  Ben Pfaff  <blp@gnu.org>
27
28         * command.def: Add DELETE VARS.
29
30 Sat Dec 16 22:15:55 2006  Ben Pfaff  <blp@gnu.org>
31
32         Make it possible to pull cases from the active file with a
33         function call, instead of requiring indirection through a callback
34         function.
35
36         * command.def: Marked MATRIX DATA as unimplemented.
37
38 Sun Dec  3 11:59:10 2006  Ben Pfaff  <blp@gnu.org>
39
40         * syntax-file.c (read_syntax_file): Always read GETL_BATCH lines.
41
42 Wed Nov 29 19:35:44 WST 2006 John Darrington <john@darrington.wattle.id.au>
43
44         * command.c: Updated to reflect changed function names.
45
46         * line-buffer.c line-buffer.h: Removed.  Guts of it moved to
47         libpspp/getl.[ch] The rest moved to files listed below.
48
49         * syntax-file.c syntax-file.h prompt.c prompt.h: New files.
50
51 Wed Nov 22 06:26:42 2006  Ben Pfaff  <blp@gnu.org>
52
53         * command.def: HOST command needs F_KEEP_FINAL_TOKEN.
54
55 Sat Oct 28 16:15:56 WST 2006 John Darrington <john@darrington.wattle.id.au>
56
57         * linebuffer.c linebuffer.h: Moved getl_buf from here, into
58         lexer/lexer.c
59
60 Thu Oct 26 20:19:00 2006  Ben Pfaff  <blp@gnu.org>
61
62         * command.def: Add DEBUG FLOAT FORMAT.
63
64 Fri Oct 20 10:59:06 WST 2006 John Darrington <john@darrington.wattle.id.au>
65
66         * command.def: Added additional unimpl commands.
67
68 Sun Oct 15 19:38:55 2006  Ben Pfaff  <blp@gnu.org>
69
70         * command.c: (do_parse_command) Issue an error for unimplemented
71         commands, instead of silently ignoring them.  Reported by John
72         Darrington.
73
74 Wed Jun 28 11:38:23 2006  Ben Pfaff  <blp@gnu.org>
75
76         Don't offer both the full and abbreviated names for a single
77         command in command name completion.
78         
79         * command.c: (enum flags) Add F_ABBREV flag.
80         (cmd_complete) Ignore command with F_ABBREV flag set.
81
82         * command.def: Add F_ABBREV to N, Q, SORT commands.
83
84 Tue Jun 27 22:36:38 2006  Ben Pfaff  <blp@gnu.org>
85
86         Fix regression in command name completion reported by John
87         Darrington.  Now completion is again state-dependent and occurs
88         only on the first line of a command.
89         
90         * command.c (do_parse_command): Move reading the first token of
91         the command here, from execute_command and cmd_input_program.
92         Call set_completion_state and getl_set_prompt_style here.
93         (do_parse_command) Use in_correct_state instead of
94         verify_valid_command.
95         (verify_valid_command) Break into two new functions,
96         in_correct_state and report_state_mismatch.
97         (set_completion_state) New function.
98         (cmd_complete) New function.
99         [HAVE_READLINE] (pspp_attempted_completion_function) Removed.
100         [HAVE_READLINE] (command_generator) Removed.
101
102         * line-buffer.c: (struct getl_source) Change `interactive' member
103         signature to take enum getl_prompt_style instead of const char *.
104         (create_interactive_source) Ditto, for parameter type.
105         (getl_append_interactive) Ditto.
106         (read_line_from_source) Pass get_prompt_style() to interactive
107         function instead of get_prompt().
108         (get_prompt) Removed.
109         (get_prompt_style) New function.
110         
111 Sat May  6 13:25:25 2006  Ben Pfaff  <blp@gnu.org>
112
113         Continue reforming procedure execution.  In this phase, remove
114         PROCESS IF, which was deprecated anyway and can be easily
115         simulated with TEMPORARY followed by SELECT IF.
116
117         * command.def: Removed PROCESS IF.
118
119 Mon May  1 18:17:52 2006  Ben Pfaff  <blp@gnu.org>
120
121         Further clean up the CMD_* command result codes.
122         
123         * command.c (cmd_result_is_valid): New function.
124         (cmd_result_is_success) Assert that argument is valid.  Simplified
125         check to one for a positive result.
126         (cmd_result_is_failure) Assert that argument is valid.  Simplified
127         check to one for a negative result.
128         (do_parse_command) Check that command's returned result is valid.
129
130         * command.h: (enum cmd_result) Renamed CMD_QUIT to CMD_FINISH and
131         updated all users.  Removed CMD_END_SUBLOOP in favor of new
132         CMD_PRIVATE_FIRST...CMD_PRIVATE_LAST range.  Changed failure codes
133         to have negative values.
134
135 Mon May  1 15:56:56 2006  Ben Pfaff  <blp@gnu.org>
136
137         Remove vestiges of FILE TYPE support. 
138         
139         * command.def: Mark FILE TYPE, RECORD TYPE unimplemented.
140
141 Wed Apr 26 21:13:46 2006  Ben Pfaff  <blp@gnu.org>
142
143         CLEAR TRANSFORMATIONS is unsafe as implemented.  It's a fair
144         amount of work to implement it correctly, so make it
145         unimplemented.
146                 
147         * command.c: (cmd_clear_transformations) Removed.
148
149         * command.def: Mark CLEAR TRANSFORMATIONS as unimplemented.
150
151 Wed Apr 26 13:06:42 2006  Ben Pfaff  <blp@gnu.org>
152
153         Work on readline completion.
154
155         * command.c: (pspp_completion_function) Removed.
156         (pspp_attempted_completion_function) New function.
157         (command_generator) New function.
158
159 Wed Apr 26 13:04:48 2006  Ben Pfaff  <blp@gnu.org>
160
161         Improve the way we handle the various parsing "states".  Until now
162         we've hard-coded the state transitions in the command definition
163         file, but that's error-prone and, worse, it's redundant--we can
164         figure out what state we're in anyhow.  We can cleanly handle
165         INPUT PROGRAM and FILE TYPE with a nested command-processing loop.
166         
167         * command.c: (cmd_result_is_success) New function.
168         (cmd_result_is_failure) New function.
169         (enum states) New enum.
170         (enum flags) New enum.
171         (struct command) Add states, flags members.  Remove transition,
172         skip_entire_name, debug members.  Renamed func member as function.
173         (macro DEFCMD) Removed.
174         (macro DBGCMD) Removed.
175         (macro SPCCMD) Removed.
176         (macro UNIMPL) Removed.
177         (macro DEF_CMD) New.
178         (macro UNIMPL_CMD) New.
179         (macro COMMAND_CNT) Changed to static const var, renamed
180         command_cnt.  Updated all references.
181         (FILE_TYPE_okay) Removed.
182         (cmd_parse) Rewrote in terms of do_parse_command().
183         (do_parse_command) New function.
184         (find_command) New function.
185         (unknown_command_error) Use struct string to simplify code.
186         (parse_command_name) Recognize comment command names.  Handle
187         flags.  Don't reject testing-mode-only commands here--let higher
188         level do it.
189         (verify_valid_command) New function.
190         (cmd_comment) New function.
191
192         * command.def: Completely rewritten and now sensibly organized.
193
194         * command.h: (enum STATE_*) Renamed CMD_STATE_*.
195         (CMD_*) Now "enum cmd_result".  Added CMD_QUIT.  New
196         CMD_END_SUBLOOP.  Removed CMD_TRAILING_GARBAGE, CMD_PART_SUCCESS,
197         CMD_PART_SUCCESS_MAYBE and replaced all references by CMD_FAILURE.
198         Added CMD_NOT_IMPLEMENTED.
199         (macro DEFCMD) Removed.
200         (macro DBGCMD) Removed.
201         (macro SPCCMD) Removed.
202         (macro UNIMPL) Removed.
203         (macro DEF_CMD) New.
204         (macro UNIMPL_CMD) New.
205
206 Mon Apr  3 11:03:36 2006  Ben Pfaff  <blp@gnu.org>
207
208         * list.q: (write_all_headers) Adapt to new html and output
209         internals.
210         (clean_up) Ditto.
211         (write_varname) Ditto.
212         (write_fallback_headers) Ditto.
213         (determine_layout) Ditto.
214         (list_cases) Ditto.
215         
216
217 Thu Mar  2 08:40:33 WST 2006 John Darrington <john@darrington.wattle.id.au>
218         
219         * Moved files from src directory