8
- Metavariables now capture the cpp code contained within their definitions
9
- When - fragments are separated by ... or nest boundaries in the semantic
10
patch, but end up matching adjacent source code, the comments, cpp code
11
and whitespace that are between them are not deleted.
12
- better parsing of C: do expansion of macros only when needed when
13
have actually a parse error and also leverage the definition of macros
14
in the parsed file (or in a optional_standard.h file passed as a parameter).
15
This should reduce the need for many hardcoded definitions in standard.h
16
- new semantics for the -macro_file option, by default now expand macros
17
only when necessary. To force use the -macro_file_builtins option instead.
18
- a new -extract_macros command line action to help the parser. Works with
19
the -macro_file option. e.g.
20
$ ./spatch -extract_macros ~/linux > /tmp/alldefs.h
21
$ ./spatch -macro_file /tmp/alldefs.h -sp_file foo.cocci -dir ~/linux
22
- removed -D macro_file option, not consistent with what -D usually means
23
- reattempt to be more efficient for statement metavariables that are just
24
placeholders (ie, no modification, no reuse)
25
- triples now returned from ctl in sorted order. The main key is the
26
state. On the other hand, the state order does not always agree with the
27
order of appearance in the code.
28
- spatch is now less verbose on the things it does yet handle. Less confusing
30
- slightly better error report. Thanks to Derek Jones for the suggestion.
31
- added the options -linux_spacing and -smpl_spacing. -linux_spacing
32
causes spatch to follow the spacing conventions of Linux, while
33
-smpl_spacing causes spatch to follow the spacing in the semantic patch.
34
-linux_spacing is the default.
35
- more informative error reporting for the already tagged token case.
36
Thanks to Erik Hovland for the suggestion.
39
- better parsing of declare macro at toplevel and in structure.
41
- allowing back typedef names for fieldname
42
- better printing of else in generated code
43
- slightly better type inference for binary operators.
44
- clear out declarer names and iterator names between SmPL files (for
46
- better parsing and type checking of macro type aliases. Cf -test macro_int16.
47
Thanks to Li Yingtong for pointing out the problem.
48
- make insert_virtual_positions tail rec, avoid stack overflow pb.
49
Thanks to Diego Liziero <diegoliz@gmail.com> for pointing out the
51
- Better type inference for arithmetic binary operators
52
Thanks to Li Yingtong for pointing out the problem.
53
- Better type inference for constants
54
Thanks to Li Yingtong for pointing out the problem.
55
- move computing of adjacency information for semantic patches to after
56
application of isomorphisms, because isomorphisms can introduce "..."
57
- compute adjacency information for negated ...
58
- record with each transformation site the set of indices of the witness
59
trees that caused the transformation site to come about. Whitespace and
60
comments between remove tokens associated with disjoint witness trees is
62
- correct treatment of function pointer typed parameters in the SmPL ast0
64
- better parsing error message and error recovery when comments are not ended,
65
when some macros have a weird body, and when some switch have a weird
67
Thanks to Derek Jones for pointing out the problem.
68
- better detection and passing of "dangerous" ifdefs, cf -test
70
- dropped the separation of decls and body in Seq. This gives better
71
positioning of the bindings of metavariables shared between them.
72
Thanks to Erik Hovland for an example that shows the problem.
75
- supress warning in compiling ocamlsexp (warning caused by a new behavior
76
of cpp used internally in processing files in ocamlsexp/)