Commit | Line | Data |
---|---|---|
34e49164 C |
1 | -*- org -*- |
2 | ||
7f004419 C |
3 | * 0.2.0 |
4 | ** Language: | |
5 | ||
6 | ** Features: | |
7 | - Remove duplicated code in disjunctions | |
8 | - Better error message when grep finds nothing relevant. Thanks to Joe | |
9 | Perches for the suggestion. | |
10 | - added -keep_comments option for the unparsing of the transformed code | |
11 | - Option "-version" now also gives information about built-in | |
12 | Python binding support. | |
9f8e26f4 C |
13 | - slightly faster environment manipulation in pathological cases |
14 | - hack added to accept well-formed #define after function header | |
7f004419 C |
15 | |
16 | ** Bugfix: | |
9f8e26f4 | 17 | - Proper consideration of #define macro arguments in checking for the use |
7f004419 | 18 | of metavariables and in computing the line numbers of complex terms |
9f8e26f4 C |
19 | - Better parsing of included .cocci files |
20 | - Put included .cocci files in the right order | |
21 | - Bind position variables only once for #include | |
22 | - Fix bug in include_match that caused everything to halt when all matches | |
7f004419 | 23 | were discarded |
9f8e26f4 C |
24 | - Merge unlikely/likely iso rules under a iso rule named unlikely |
25 | - Some fixes to coccicheck rules, thanks to Andrew Lunn | |
26 | - Support groups in regular expression, thanks to Michael Stefaniuc | |
7f004419 | 27 | |
951c7801 C |
28 | * 0.1.11 |
29 | ||
30 | ** Language: | |
31 | - Meta-identifier/function and constant could be filtered from SmPL by | |
32 | regular expressions using the "~=" and "!~=" operators followed by | |
33 | an OCaml regular expression (see man Str) in double quote. | |
7f004419 C |
34 | - Virtual rules, which can be referenced in depends, and set and unset |
35 | using the command-line options -D | |
36 | - ++ for multiple additions | |
951c7801 C |
37 | |
38 | ** Features: | |
951c7801 C |
39 | - coccicheck: a framework to check a series of SmPL files on a project |
40 | see scripts/coccicheck for more information | |
41 | ||
42 | ** Bugfix: | |
43 | - bind position variables to the correct starting position in the case of a | |
44 | complex statement such as an if or while. Thanks to Derek Jones for | |
45 | pointing out the problem. | |
46 | - checking for non mentioned case lines in switch should be unchecked. | |
47 | - space should be printed after sizeof when there are no parentheses around | |
48 | the argument. Thanks to Daniel Walker for pointing out the problem. | |
49 | - avoid introducing sharing in propagating ! over () in treatment of isos | |
50 | - save_excursion has to handle and rethrow exceptions | |
51 | - eliminate unnecessary consideration of CVS strings. Thanks to David | |
52 | Young for pointing out the problem. | |
53 | - completely new treatment of statement metavariables | |
951c7801 C |
54 | - better type checking for macro definitions |
55 | - drop regression testing in -parse_c | |
56 | ||
fc1ad971 C |
57 | * 0.1.10 |
58 | ||
59 | ** Language: | |
60 | - declarations allowed in switch, suggested by Derek M. Jones | |
61 | ||
62 | ** Features: | |
63 | - use interval timer for timeouts. Thanks to Derek M. Jones for the | |
64 | implementation. | |
65 | - more flexible env.sh, thanks to Derek Jones. | |
66 | - faster Python invocation | |
67 | - simplify unparsing in the sgrep case | |
68 | ||
69 | ** Bugfix: | |
70 | - for glimpse there is no point to create a pattern containing a numeric | |
71 | constant because glimpse doesn't index them | |
72 | - add spaces after commas in function calls and function headers | |
73 | - made python integration more like the ubuntu version | |
74 | http://patches.ubuntu.com/by-release/extracted/debian/c/coccinelle/0.1.5dbs-2/01-system-pycaml | |
75 | this fixes some memory management problems with None, True, and False | |
76 | - correct labels associated with a switch in the CFG so that a statement | |
77 | metavariable can match a switch. Thanks to Derek Jones for pointing out | |
78 | the problem. | |
79 | - keep switch pattern within switch body. Thanks to Derek Jones for | |
80 | pointing out the problem. | |
81 | - Allow expanded tokens to be stored in metavariables, as long as they are | |
82 | not removed. But this does currently allow them in + code, which will | |
83 | produce the expansion. Thanks to Ali-Erdem Ozcan for pointing out the | |
84 | problem. | |
85 | - improved adjustment of spacing when code removed at the beginning of a line | |
86 | ||
978fd7e5 C |
87 | * 0.1.9 |
88 | ||
89 | ** Language: | |
90 | - allow fresh identifiers to be declared using ## such that the value mixes | |
91 | both strings and previously declared metavariables | |
92 | ||
93 | ** Features: | |
94 | - better handling of expanded code containing ##. Now compute the | |
95 | result. | |
96 | - more precise warning message for the "'\' outside define". | |
97 | Thanks to Nicholas Mc Guire for pointing out the problem. | |
98 | - more precise warning message related to ifdefization. | |
99 | Thanks to Derek Jones for pointing out the problem. | |
100 | - we don't create any more certain files in /tmp (they may be a cause | |
101 | of security problems). | |
102 | Thanks to Eugeniy Meshcheryakov for pointing out the problem. | |
103 | - More optimization for the case of just deleting a complete function. | |
104 | Allows this to happen without tracing through all the control-flow | |
105 | paths. Thanks to Francois Bissyande for pointing out the problem. | |
106 | - prevent code from being added to the beginning or end of a disjunction | |
107 | - more information about why a script is not applied when using -debug option | |
108 | - added -no_safe_expressions option | |
109 | - added -no_loops option. Ignores back edges derived from looping | |
110 | constructs. This is unsafe, but perhaps useful for bug finding, as it can | |
111 | be more efficient. | |
112 | - for semantic matches, allow "minus" on same code with multiple | |
113 | environments | |
114 | - better error message for mismatch of parenthesis in column 0 with normal | |
115 | parenthesis. Thanks to Derek Jones for pointing out the problem. | |
116 | - allow disjunctions on function return types. Thanks to Pierre Habouzit | |
117 | for pointing this out. | |
118 | ||
119 | ** Bugfix: | |
120 | - keep disjunction in the proper order for structure initialization fields | |
121 | - variables declared in different places should not seem to match each | |
122 | other | |
123 | - drop complaints about label metavariables not being used | |
124 | - drop test information from the type of an expression when the expression | |
125 | is bound to a metavariable | |
126 | - nests should not extend beyond the before and after code, even if the | |
127 | before and after code matches the nest code | |
128 | - nests should extend into conditionals that end in error exit | |
129 | - take into account metavariables on "else". Thanks to Derek Jones for | |
130 | pointing out the problem. | |
131 | - print single quotes on generated character constants | |
132 | - better typedef handling in the initialisation/affectation builtin | |
133 | isomorphism, cf -test init_affect_typedef | |
134 | - support disjunction of types on variable declaration | |
002099fc C |
135 | - allow @ within strings in script code. ignore // comment lines in script |
136 | code. | |
137 | - don't drop + code placed after the transformed code | |
138 | - drop spaces produced by removing code before semicolons | |
139 | - adjusted spacing within generated code | |
140 | - less verbose -sp. Thanks to Derek Jones for pointing out the problem. | |
141 | - accept multiple type names in a SmPL typedef declaration. | |
978fd7e5 | 142 | |
708f4980 C |
143 | * 0.1.8 |
144 | ||
145 | ** Language: | |
146 | ||
147 | ** Features: | |
148 | - Metavariables now capture the cpp code contained within their definitions | |
149 | - When - fragments are separated by ... or nest boundaries in the semantic | |
150 | patch, but end up matching adjacent source code, the comments, cpp code | |
151 | and whitespace that are between them are not deleted. | |
152 | - better parsing of C: do expansion of macros only when needed when | |
153 | have actually a parse error and also leverage the definition of macros | |
154 | in the parsed file (or in a optional_standard.h file passed as a parameter). | |
155 | This should reduce the need for many hardcoded definitions in standard.h | |
156 | - new semantics for the -macro_file option, by default now expand macros | |
157 | only when necessary. To force use the -macro_file_builtins option instead. | |
158 | - a new -extract_macros command line action to help the parser. Works with | |
159 | the -macro_file option. e.g. | |
160 | $ ./spatch -extract_macros ~/linux > /tmp/alldefs.h | |
161 | $ ./spatch -macro_file /tmp/alldefs.h -sp_file foo.cocci -dir ~/linux | |
162 | - removed -D macro_file option, not consistent with what -D usually means | |
163 | - reattempt to be more efficient for statement metavariables that are just | |
164 | placeholders (ie, no modification, no reuse) | |
165 | - triples now returned from ctl in sorted order. The main key is the | |
166 | state. On the other hand, the state order does not always agree with the | |
167 | order of appearance in the code. | |
168 | - spatch is now less verbose on the things it does yet handle. Less confusing | |
169 | for new users. | |
170 | - slightly better error report. Thanks to Derek Jones for the suggestion. | |
171 | - added the options -linux_spacing and -smpl_spacing. -linux_spacing | |
172 | causes spatch to follow the spacing conventions of Linux, while | |
173 | -smpl_spacing causes spatch to follow the spacing in the semantic patch. | |
174 | -linux_spacing is the default. | |
175 | - more informative error reporting for the already tagged token case. | |
176 | Thanks to Erik Hovland for the suggestion. | |
177 | ||
178 | ** Bugfix: | |
179 | - better parsing of declare macro at toplevel and in structure. | |
180 | cf -text xfield | |
181 | - allowing back typedef names for fieldname | |
182 | - better printing of else in generated code | |
183 | - slightly better type inference for binary operators. | |
184 | - clear out declarer names and iterator names between SmPL files (for | |
185 | -testall) | |
186 | - better parsing and type checking of macro type aliases. Cf -test macro_int16. | |
187 | Thanks to Li Yingtong for pointing out the problem. | |
188 | - make insert_virtual_positions tail rec, avoid stack overflow pb. | |
189 | Thanks to Diego Liziero <diegoliz@gmail.com> for pointing out the | |
190 | problem. | |
191 | - Better type inference for arithmetic binary operators | |
192 | Thanks to Li Yingtong for pointing out the problem. | |
193 | - Better type inference for constants | |
194 | Thanks to Li Yingtong for pointing out the problem. | |
195 | - move computing of adjacency information for semantic patches to after | |
196 | application of isomorphisms, because isomorphisms can introduce "..." | |
197 | - compute adjacency information for negated ... | |
198 | - record with each transformation site the set of indices of the witness | |
199 | trees that caused the transformation site to come about. Whitespace and | |
200 | comments between remove tokens associated with disjoint witness trees is | |
201 | not removed. | |
202 | - correct treatment of function pointer typed parameters in the SmPL ast0 | |
203 | visitor. | |
204 | - better parsing error message and error recovery when comments are not ended, | |
205 | when some macros have a weird body, and when some switch have a weird | |
206 | Body. | |
207 | Thanks to Derek Jones for pointing out the problem. | |
208 | - better detection and passing of "dangerous" ifdefs, cf -test | |
209 | double_switch. | |
210 | - dropped the separation of decls and body in Seq. This gives better | |
211 | positioning of the bindings of metavariables shared between them. | |
212 | Thanks to Erik Hovland for an example that shows the problem. | |
213 | ||
214 | ** Internals: | |
215 | - supress warning in compiling ocamlsexp (warning caused by a new behavior | |
216 | of cpp used internally in processing files in ocamlsexp/) | |
217 | ||
b1b2de81 C |
218 | * 0.1.7 |
219 | ||
220 | ** Language: | |
221 | - initialize and finalize script code, cf demos/initial_final.cocci | |
222 | ||
223 | ** Features: | |
224 | - -iso_limit option to limit the depth of isomorphism application | |
225 | - with the dir option, the include path is implicitly set to the "include" | |
226 | subdirectory of the specified directory, if the option -I is not used. | |
227 | - give a seed for the name of a fresh identifier | |
228 | - better handling of cpp "constructed" identifiers as in a##b, that in | |
229 | the futur will make it easier to match over those idents. | |
230 | cf tests/pb_parsing_macro.c. Thanks to Ali-Erdem Ozcan for pointing | |
231 | out the problem. A new "parsing hack hint" is also available: | |
232 | YACFE_IDENT_BUILDER, cf standard.h. | |
233 | ||
234 | ** Bugfix: | |
235 | - drop excessive "optimization" in ctl generation for while and for loops | |
236 | - allow . as the name of the directory | |
237 | - for type inference for an assignment, take the type of the right-hand | |
238 | side expression, not the type of the assigned variable | |
239 | - allow for with a declartion in the first header element, as in C++ | |
240 | (partial support) | |
241 | - allow for matching against variable declarations that include only | |
242 | storage, eg static, but no type at all. | |
243 | - allow for matching against types that contain both short/long and int | |
244 | - allow the type metavariable in the SmPL code "unsigned T" to match a T | |
245 | that is a type consisting of more than one word, eg long int. | |
246 | - -ifdef_to_if option made to process nested ifdefs | |
247 | (partial support) | |
248 | ||
249 | ** Internals: | |
250 | - improve and fix installation process (usable on BSD) | |
251 | - improve and fix testing process | |
252 | - apply patches from Eugeniy Meshcheryakov | |
253 | - reorganize the way we parse C identifiers, especially concatenated cpp | |
254 | identifiers as in a##b. This may lead to some regressions as we may | |
255 | not parse as much code as before. | |
256 | - removed popl/ and popl09/ and popl related stuff from official distrib. | |
257 | ||
0708f913 | 258 | * 0.1.6 |
113803cf | 259 | |
b1b2de81 C |
260 | ** Language: |
261 | - the ability to add comments | |
262 | ||
113803cf | 263 | ** Features: |
0708f913 C |
264 | - grouping of generated rules with -hrule option |
265 | - handling of special coccinelle comments | |
266 | /* {{coccinelle:skip_start}} */ and | |
267 | /* {{coccinelle:skip_end}} */ | |
268 | allowing to give more hints to the C parser. | |
269 | Thanks to Flavien@lebarbe.net for the idea. | |
0708f913 C |
270 | - the ability to print the values of more (but not all) kinds of |
271 | metavariables from python | |
272 | - new vim SmPL mode. | |
273 | Thanks to Alexander Faroy. | |
274 | ||
275 | ** Bugfix: | |
276 | - consider the ident tokens also in the 2 lines before the error line for the | |
277 | 10-most-problematic-parsing-errors diagnostic. | |
278 | - SmPL parser allows cast as the argument of a pointer | |
279 | - SmPL type checker allows enum as an array index | |
280 | - Better generation of fresh metavariables names in hrule | |
281 | - no more warnings about things that should be metavariables when there is | |
282 | a disjunction in a function position | |
283 | - bugfix in parser, better error message. | |
284 | Thanks to Ali-Erdem OZCAN <ali-erdem.ozcan@st.com> for the bug report. | |
285 | ||
286 | ** Internals: | |
287 | ||
288 | * 0.1.5 | |
289 | ||
290 | ** Language: | |
113803cf C |
291 | - added initialiser metavariable |
292 | - added sequences of designators in structures | |
0708f913 C |
293 | |
294 | ** Features: | |
113803cf C |
295 | - improved printing of the C code corresponding to metavariables |
296 | - improved printing when code (eg declarations) is removed at the beginning | |
297 | of a block, and then is followed by a blank line | |
298 | - slightly less verbose error reporting in parsing_hacks | |
299 | ||
300 | ** Bugfix: | |
301 | - fixed some problems with parsing SmPL code where a nest appears after a | | |
302 | - better treatment of { }, form in macros wrt unparse_c | |
303 | - less quiet for -parse_c | |
304 | - improve parsing heuristics regarding macro statement | |
305 | ||
306 | ** Internals: | |
307 | ||
faf9a90c C |
308 | * 0.1.4 |
309 | ||
0708f913 C |
310 | ** Language: |
311 | - long long added to SmPL | |
312 | ||
708f4980 C |
313 | ** Documentation: |
314 | - add grammar reference and spatch command line options reference | |
315 | ||
faf9a90c C |
316 | ** Features: |
317 | - can match patterns of the form unsigned T or signed T, where T is a | |
318 | metavariable | |
319 | - dropped the sizeof_parens isomorphism, which was made redundant by the | |
320 | paren isomorphism | |
321 | - simple rule generation | |
faf9a90c C |
322 | |
323 | ** Bugfix: | |
324 | - trailing , ; and ) no longer left on a line by themselves | |
325 | - better treatment of error exit when the searched for code matches the | |
326 | error exit condition. | |
327 | - fix incorrect treatment of parentheses in test_exps that could allow + | |
328 | code to be added twice | |
329 | - don't ask whether iterator names and declarer names should be declared as | |
330 | metavariables. | |
331 | - slightly better support for expression list metavariables. | |
332 | - short and long allowed for array index types in SmPL | |
333 | - more restrictions on type inference for pointer arithmetic in SmPL | |
334 | - allow isomorphisms to apply when + code is anywhere within all - terms | |
335 | - changed order of printing const and volatile | |
336 | - allow eg ... <... in plus code | |
337 | - better formatting of generated if/while/etc. code | |
338 | - better parse error reporting when the problem is at the end of the file | |
339 | ||
340 | ** Internals: | |
341 | - isomorphisms don't apply under signed/unsigned, to prevent the creation | |
342 | of things like unsigned signed int. Need a better solution for this. | |
343 | ||
708f4980 | 344 | |
91eba41f C |
345 | * 0.1.3 |
346 | ||
347 | ** Features: | |
348 | - help in building the configuration macro file. The -parse_c action | |
349 | now returns the 10 most frequent parsing errors. This give useful | |
350 | hints to extend standard.h. | |
351 | ||
352 | ** Bugfix: | |
353 | - positions no longer allowed on \(, \|, and \) | |
354 | - improved propagation of negation for isos in the presence of parens | |
355 | - convert Todos in flow graph construction to recoverable errors | |
356 | - fixed bug in treatment of when != true and when != false, to allow more | |
357 | than one of them per ... | |
358 | - improve parsing of typedef of function pointer. | |
359 | - improve typing. | |
360 | - parsing and typing support for old style C function declaration. | |
361 | - consider position variables as modifications when optimizing the | |
362 | translation into CTL of function definitions | |
363 | ||
364 | ** Internals: | |
365 | ||
485bce71 C |
366 | * 0.1.2 |
367 | ||
368 | ** Bugfix: | |
369 | - better handling of ifdef on statements in control flow graph. | |
370 | - transform files even if they do not end in .c (thanks to Vegard Nossum) | |
371 | ||
372 | ** Internals: | |
373 | - merge code of yacfe | |
374 | ||
1be43e12 C |
375 | * 0.1.1 |
376 | ||
0708f913 | 377 | ** Language: |
485bce71 | 378 | - support for initializer at toplevel, cf -test substruct |
1be43e12 | 379 | |
34e49164 C |
380 | * 0.1 |
381 | ||
382 | ** first public release of the source code: | |
383 | ||
0708f913 | 384 | ** Language: |
34e49164 C |
385 | - embeded python scripting |
386 | - position | |
387 | ||
0708f913 C |
388 | ** Features |
389 | ||
34e49164 C |
390 | * beta |
391 | ||
392 | ** first public release of the binary | |
393 | ||
394 | * alpha | |
395 | ||
396 | ** Features | |
397 | - lots of features ... look at coccinelle research papers and tutorials. |