[cfe-dev] Indexer Library and type references....

dan chap dchapiesky at yahoo.com
Thu Oct 8 13:46:38 PDT 2009



--- On M
Shifting namespaces sounds like a syntactic transformation rather than a transformation that needs to work on the AST.


Yes... It is syntactic...   I am working on a refactoring tool (ala Netbeans Refactor/Rename) and I am using the Clang AST and indexer library to produce source locations and references not only against the primary project you were working on, but also within projects which depend upon the primary one...    

For example... (this is a very simple example and not necessarily a good one at that...)

You have a large project which has been code reviewed and regression tested to within an inch of it's life.   It uses zlib 1.1.0 and does a fine job.

References to zlib are sprinkled throughout hundreds of modules and locations.

Now, a new version of zlib is available: 1.2.3 and you need it's functionality for an additional module being created in the project.

By massively refactoring the source code of zlib 1.2.3 to a new namespace (not C++ , just plain vanilla C) so that you get something like zlib_123_deflate(), you will not namespace collisions between the old and new zlib when linking.

We have preserved our code reviewed source code and we have ensured that there is no weird stuff going on during the link cycle.

Anyway,  preserving code reviewed code is the primary purpose of my refactor tool...  

I will be making a beta available to the group in a couple of weeks with a cute wxwidgets front end.  




....but someone will need to go through and add this information for us to maintain all type source information for expressions and statements.

    - Doug

That will probably be me... :)

Daniel




      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20091008/8ad466d2/attachment.html>


More information about the cfe-dev mailing list