[cfe-dev] libtooling ClangTool::run question for EmitLLVMOnlyAction

Adrian Ortega elfus0.1 at gmail.com
Sat Aug 16 15:55:21 PDT 2014


I am trying to run an EmitLLVMOnlyAction using libtooling. I am 
following this webpage 

And it actually works, but what I'm trying to do next is to get the 
llvm::Module by using the llvm::CodeGenAction::takeModule() method. I 
took a quick look at the code, and seems that for every translation unit 
a different FrontendAction (EmitLLVMOnlyAction).

The question is:
Is there a way to get a pointer to that FrontendAction 
(EmitLLVMOnlyAction) created by ClangTool so I can play with the 

More information about the cfe-dev mailing list