[cfe-dev] Python bindings overhaul
tobias at grosser.es
Wed Feb 1 23:57:35 PST 2012
On 02/02/2012 01:00 AM, Eric Christopher wrote:
> Hi Gregory!
> On Jan 27, 2012, at 2:41 PM, Gregory Szorc wrote:
>> Major changes:
>> * Enumerations split out into clang.cindex.enumerations module
>> * Objects hold references to parent (i.e. worry-free memory management)
>> * Support for Token API
>> * More APIs supported around the board. Pretty much everything from
>> libclang is supported except the high-level Indexing component.
>> Other improvements:
>> * Python style improvements. pylint and pyflakes output is now
>> tolerable and the code mostly follows Python best practices.
>> * Improved documentation
>> * Increased test coverage
>> * Added test to ensure enumerations are up-to-date with Index.h (uses
>> Tokens API)
>> * Introduced decorator to cache/lazy load properties. This should cut
>> down on C function calls.
> This all sounds awesome. How about we start small here though? You've
> mentioned that you have a bunch of cleanups for eye sores, doxygen
> comments, etc that we could apply on our way to having the python
> bindings get feature parity with libclang. Let's get some of those reviewed
> separately and then tackle the larger tasks as we go?
> Thanks again for all of this work, I haven't had time to look at your
> github repository but hope to soon!
just to give you some first feedback right now. I skimmed trough the git
repository and I like the overall direction of the patches. They seem to
improve the python bindings a lot. Unfortunately I did not have time to
look into the exact details.
I think the patch is very large. This is good to show the overall
direction. However, to commit and review these changes I would very much
appreciate smaller patches. As I have seen in your git repository, you
have all this already divided in small patches. Most of them seem to be
easy to review.
I will give it another look (either today or tomorrow). I will also try
your changes with clang_complete. If there are no big blockers (wait
also for Erics review), I would propose to slowly commit the changes to
svn. You could commit trivial fixes without pre-commit review and other
changes could be posted in batches of five to get them reviewed. As they
are split up in small portions, reviewing them should be fast.
Thanks again for your great work!
More information about the cfe-dev