-*- org -*- * 0.3 ** Documentation: - extended readme.txt to explain how quickly evaluate how much yacfe can parse your C source code - improve yacfe-internal.pdf (based on CC'09 anonymous reviewers feedback). ** Language: - reorganize the way we parse C identifiers, especially concatenated cpp identifiers as in a##b. This may lead to some regressions as we may not parse as much code as before. - allow for with a declartion in the first header element, as in C++ (partial support) - cpp_ast_c.ml, for include and ifdef statement grouping - improve control_flow to handle ifdef - better parsing and type checking of macro type aliases. Cf -test macro_int16. Thanks to Li Yingtong for pointing out the problem. ** Parsing: - give the 10 most problematic identifier tokens found in the line where a parsing error occured. Also give one example of a line containing such a problematic identifier. Helps to build a macro configuration file. (suggested by a CC'09 anonymous reviewer). - better handling of cpp "constructed" identifiers as in a##b, that in the futur will make it easier to match over those idents. cf tests/pb_parsing_macro.c. Thanks to Ali-Erdem Ozcan for pointing out the problem. A new "parsing hack hint" is also available: YACFE_IDENT_BUILDER, cf standard.h. - better parsing of C: do expansion of macros only when needed when have actually a parse error and also leverage the definition of macros in the parsed file (or in a optional_standard.h file passed as a parameter). This should reduce the need for many hardcoded definitions in standard.h - new semantics for the -macro_file option, by default now expand macros only when necessary. To force use the -macro_file_builtins option instead. - a new -extract_macros command line action to help the parser. Works with the -macro_file option. e.g. $ ./spatch -extract_macros ~/linux > /tmp/alldefs.h $ ./spatch -macro_file /tmp/alldefs.h -sp_file foo.cocci -dir ~/linux - better parsing of declare macro at toplevel and in structure. cf -text xfield - handling of special coccinelle comments /* {{coccinelle:skip_start}} */ and /* {{coccinelle:skip_end}} */ allowing to give more hints to the C parser. Thanks to Flavien@lebarbe.net for the idea. ** Applications: - GUI a la lxr and kscope that internally also uses glimpse and SmPL queries. - advanced code visualizer using semantic information to give visual feedbacks (function pointer expression, globals in bigger size, multi_def functions underlines, etc) - caller/callee protocol checker ** Features: - callgraph_c.ml - function pointer alias analysis (used by callgraph) in aliasing_function_c.ml - database_c.ml and relation_c.ml (for inter-procedural analysis). - more information in database_c.ml (used by GUI) - emacs_mode_c.ml (used by GUI) - database_c_query.ml: query capabilities for glimpse, grep, smpl, protocols, types and symbols - better type annotater and type reannotater using global information ** Internals: - rename parsing_c++ in parsing_cplusplus for ocamlbuild, thanks to ygrekheretix@gmail.com. - add some statistics for parsing/typing/callgraph to see coverage - use PCRE instead of Str (str is buggy) - use Berkeley DB instead of gdbm (gdbm seems buggy for large tables) - split yacfe in 2 packages, yacfe and yacfe-light so people just wanting the parser have less dependencies - sync with coccinelle 0.1.8 ** Bugfix: - better cpp_ast, bugfix + optimisation and fault tolerance - better type annotater, cleaner code + symbol table for enum and macro, and handling of union and anonymous nested structure => on sparse now get 95% of typing coverage (vs 30% in yacfe 0.2) - allowing back typedef names for fieldname - better parsing of declare macro at toplevel and in structure. cf -text xfield - for type inference for an assignment, take the type of the right-hand side expression, not the type of the assigned variable - consider the ident tokens also in the 2 lines before the error line for the 10-most-problematic-parsing-errors diagnostic. - bugfix in parser, better error message. Thanks to Ali-Erdem OZCAN <ali-erdem.ozcan@st.com> for the bug report. * 0.2 ** Language: - more ifdef in the ast - some support for attributes. ** Bugfix: - complete missing cases in pretty_print_c.ml ** Misc: - packagize a little (a readme.txt, configure, etc) ** Documentation: - readme.txt - demos/zero_to_null.ml * 0.1 ** first public release of the source code (September 2008) (wait public release of coccinelle, from which yacfe is extracted) ** Documentation: - yacfe-internal.pdf (draft of paper submitted to CC'09). * beta ** 2008: - first parsing_c++/ tentative. *** Features: - statistics_c.ml - comment_annotater.ml (for ICSE'08 paper) *** Parsing: - Parsing_hacks hint in macro file. *** Language: - cpp directives and ifdef in ast (less passing) for CC'09 paper. ** 2007: *** Features: - type_annotater_c.ml - Better matcher_c/ for Eurosys'08 paper. *** Parsing: - Parsing_hacks views and fresh tokens support. *** Language: - Support for define macro body, especially useful to improve stat when parsing header files. - Many cpp extensions. ** 2006: *** Features: - matcher_c/ (using monad trick) with cocci_vs_c.ml, pattern.ml, transformation.ml - unparsing, unparse_c.ml, pretty_print_c.ml - control_flow_c.ml, ast_to_flow.ml, flow_to_ast.ml (deprecated now) - visitor_c.ml (using continuation trick). *** Parsing: - Parsing_hacks lookahead() and basic typedef inference handling in parsing_hacks.ml and token_helpers.ml *** Language: - Many gcc extensions. - A few cpp extensions. * alpha ** 2005: *** Parsing: - parse_c.ml, parsing driver with error recovery (for Eurosys'06) but that still pass over most cpp directives and macros. *** Features: - Statistics on Linux ** 2002: *** Features: - First tentative of C type checker. *** Language: - Basic AST, lexer, grammar, inspired by http://www.lysator.liu.se/c/ANSI-C-grammar-l.html http://www.lysator.liu.se/c/ANSI-C-grammar-y.html in ast_c.ml, lexer_c.mll, parser_c.mly, and initial typedef trick in lexer_parser.ml