Zhang HanSheng
Zhang HanSheng

Reputation: 342

Is there any mid-representation between LLVM IR and source code?

For example, A line of objective-C code [NSData alloc] will be transformed into a call to objc_msgSend. Is there any method I can intercept this level's representation with out getting into these LLVM IR mess? Thanks

Upvotes: 1

Views: 141

Answers (1)

box
box

Reputation: 3246

If you use Clang as a front end for Objective C, then you can also work on its Abstract Syntax Tree (AST) which is close to the parsed source code. You can have a look at http://clang.llvm.org/docs/IntroductionToTheClangAST.html to get started.

Upvotes: 1

Related Questions