[cfe-commits] [PATCH] Implement a better plugin API for clang

Jordan Rose jordan_rose at apple.com
Thu Jun 21 08:56:14 PDT 2012


On Jun 21, 2012, at 7:29 AM, Joshua Cranmer wrote:

> On 6/21/2012 10:17 AM, Nico Weber wrote:
>> Is this ASTConsumer run in addition to codegen, instead of codegen, or 
>> is there an option to choose? I'd like to be able to have a plugin 
>> that runs in addition to codegen, which only provides additional 
>> diagnostics. 
> 
> In addition to. As I mentioned earlier, the use case of running a plugin 
> in lieu of codegen is one that I do not want to even support in the 
> first place. :-)

I think it's still interesting to be able to run plugin actions instead of CodeGen. It's not certain yet, but we're (the static analyzer team) looking at plans to extract the analyzer and possibly the various Objective-C rewriters out of the main clang binary (or at least make them optionally built), and we'd rather not distribute two copies of Basic, Lex, Parse, AST, Sema, etc. that these kinds of alternate ASTActions would need.

(This is still in very early stages; it's possible our final solution won't end up using the existing, admittedly-flawed plugin structure.)

I'll try to actually review your proposal fairly soon; this just caught my eye.




More information about the cfe-commits mailing list