[cfe-dev] Using Clang for a C Refactoring Tool

Yan rottled at gmail.com
Fri Apr 11 09:48:37 PDT 2008


Ha ha, I'd like to chime in, that I too had a similar idea. I wanted to
create a framework and a visual representation of source files for manual
auditing and browsing of source. The idea is to better model code/data flow,
abstract away the notion of files/modules and in general make code browsing
akin to following symbolic execution statically.

Is anyone planning to make what you are talking about an open project or
does anyone else share an interest for this?

I'd love to know.

Thanks,
Yan

On Fri, Apr 11, 2008 at 6:17 AM, <pingu219 at gmail.com> wrote:

> Same here! If only to see how easy/hard it is to build a refactoring
> tool using Clang.
>
> On 4/11/08, Chris Lattner <clattner at apple.com> wrote:
> >
> >
> > On Apr 10, 2008, at 5:59 PM, Patrick Flannery wrote:
> >
> >
> > >Additionally, I  suspect we'd welcome code to do more in this area into
> the
> > tree.  I
> > >think clang would be a good place to do this.
> > >Also, because clang (and llvm) is built and designed as a set of
> > >useful libraries for solving all sorts of problem, if there is a rough
> > >area where the design could be improved to meet your specific needs, I
> > >think we are interested in have that flexibility in clang.
> >
> >
> >
> > Refactoring is my goal as well.  I was originally attracted to clang
> because
> > its design yields a much more expressive tree structure with detailed
> source
> > locations, this makes refactoring easy in many situations.  I had a
> brief
> > list of refactorings that I had worked on, for example renaming
> functions
> > and variables, moving sections of code to different files and listing
> > #include's which are not required in a given translation unit.  If there
> was
> > some community interest in this, I would very much like to contribute my
> > work.  One area which I have not spent enough time thinking about is
> what an
> > interface for refactoring should look like.  If people had some
> suggestions
> > regarding what they would like to see and how the respective pieces
> should
> > interact I would appreciate it.
> >
> > This is very interesting, I'd love to see what you've been working on!
> >
> > -Chris
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20080411/e846f76e/attachment.html>


More information about the cfe-dev mailing list