summaryrefslogtreecommitdiffstats
path: root/ppapi/generators/idl_node.py
Commit message (Collapse)AuthorAgeFilesLines
* More multi-version support (part 2)noelallen@google.com2011-08-251-0/+11
| | | | | | | | | | | | | | | | | | | | Add member to Node to return a set of unique releases for that node. Updates DefineStruct to iterate across all unique releases for the struct, generating first the most recent release as we do today and other releases without comments, and the version number appended to the structure name. NOTE: This is work in progress. This CL adds support for Interfaces that change which should be enough for M15. While this same CL creates multiple structures when the structures change, references to structures will not have mangled names which would cause errors. BUG= http://code.google.com/p/chromium/issues/detail?id=89969 TEST= python generator.py --cgen --test --diff --range=M13,M14 Review URL: http://codereview.chromium.org/7751001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@98298 0039d316-1c4b-4281-b951-d872f2087c98
* More multi-version supportnoelallen@google.com2011-08-241-0/+5
| | | | | | | | | | | | | | | | | | | | | | Minor fix to idl_output: switch from None to '' to alow split to work Add 'InReleases' member to verify node is valid within a list of releases. Add 'releases' member to IDLVersionMap class for easier search. Remove stale code and build ordered list of requested releases in AST Remove release member from CGen object, and pass into functions Move release tracking from C prototype to C header generator Update generator tests. Added golden files to verify the C generator is correct NOTE: This is work in progress. The header emitted using --release=X should be correct and has been tested to generate exactly what we have today, however --range=X,Y does not yet generate what we need. BUG= http://code.google.com/p/chromium/issues/detail?id=89969 TEST= python generator.py Review URL: http://codereview.chromium.org/7715036 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@98133 0039d316-1c4b-4281-b951-d872f2087c98
* Update the generatornoelallen@google.com2011-07-191-2/+5
| | | | | | | | | | | | | | | | | | | | Outstanding changes to the generator to: Support hashing Support versions Clean up 'C' header generation Update of 'C' header generation tests Fix line wrapping Pass error counts through to File objects BUG= http://code.google.com/p/chromium/issues/detail?id=84272 TEST= python idl_c_header.py & gcl try Generate the new headers, add them to a CL, and try TBR= sehr@google.com Review URL: http://codereview.chromium.org/7408002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92930 0039d316-1c4b-4281-b951-d872f2087c98
* IDLNode cleanup and use of new IDLNamespace objectnoelallen@google.com2011-07-141-171/+274
| | | | | | | | | | | | | | | | | | | | A few basic cleanups, like removing the need for a 'BuildTree' step. Moved the namespace work to the IDLNamespace object Added tests for properties, text manipulations, etc... Also added IDLVersion from which IDLNode is now derived. IDLVersion helps support node versioning. Broke out IDLAst from idl_node.py, to make dependencies cleaner. So that IDLNamespace depends on IDLNode, and IDLAst depends on IDLNamesapce. Same with version... IDLNamespace depends on IDLVersion, so does IDLNode. NOTE: IDLNamespace is in another CL BUG= http://code.google.com/p/chromium/issues/detail?id=87684 TEST= python idl_node.py && python idl_version.py Review URL: http://codereview.chromium.org/7289004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92548 0039d316-1c4b-4281-b951-d872f2087c98
* Fix 'C' header generationnoelallen@google.com2011-06-071-0/+1
| | | | | | | | | | | | | | Added chidlist which provides in-order access to node children. Extra warning information on idl_parse. Added 'srcdir' to parser for prepending path Added header generator Fixed minor errors in idl_c_proto BUG= http://codereview.chromium.org/7085014/ TEST= python idl_c_header.py --srcdir="../api" *.idl Review URL: http://codereview.chromium.org/7056069 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@88079 0039d316-1c4b-4281-b951-d872f2087c98
* Add idl_c_proto for generating 'C' style prototypes from IDLnoelallen@google.com2011-06-021-3/+38
| | | | | | | | | | | | | | | Updated idl_log to provide Log/LogTag (which add the log type tag) Remove stale switches to idl_lexer.py Add Regex based Replace function to Node to replace $KEY$ with a property on that node Added quick resolution of typeinfo by adding typeinfo member to IDLNode Added idl_c_proto.py which defines a set of function which take an IDL Node then generate the 'C' style equivelent. BUG= http://code.google.com/p/chromium/issues/detail?id=84272 TEST= python idl_c_proto.py Review URL: http://codereview.chromium.org/7085014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@87567 0039d316-1c4b-4281-b951-d872f2087c98
* IDL cleanup, added AST node, namespace, StageResultnoelallen@google.com2011-05-041-3/+96
| | | | | | | | | | | | | | Added the ability to track namespace within the tree to look for references. Added a BuildTree and Resolve step. Added a StageResult object to return partial trees and error counts. Built test search into parser so now test files no longer need to be specified on the command line. BUG=77551 TEST= python idl_parser.py --test Review URL: http://codereview.chromium.org/6903097 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84086 0039d316-1c4b-4281-b951-d872f2087c98
* IDL Cleanup - add logger, and nodenoelallen@google.com2011-04-261-0/+128
Cleanup parser by splitting out logging function and an AST node object. Cleanup use of 'lineno' by starting the lexer on line 1 instead of line 0. BUG= 77551 TEST= python idl_parser.py --test test_parser/*.idl Review URL: http://codereview.chromium.org/6905006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83049 0039d316-1c4b-4281-b951-d872f2087c98