[LLVMdev] Find function parameters (original) (raw)
Victor Campos vhscampos at gmail.com
Sun Mar 30 11:14:04 PDT 2014
- Previous message: [LLVMdev] Find function parameters
- Next message: [LLVMdev] Disable JIT and interpret code instead in VMKit
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hi,
you can iterate over a function's formal parameters via Function::arg_iterator.
Regards, Victor.
On Sun, Mar 30, 2014 at 12:33 PM, lucefe <noviceup at gmail.com> wrote:
Hi,
For each variable, I want to figure out whether it is a parameter or not. How should I do that? For example, in the next function, I want to know that variable 'i' is a parameter, and 'var' is a variable. int test (int i) { int var; var = 2*i; return var; } Thanks in advance. lucefe
LLVM Developers mailing list LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20140330/bda2b731/attachment.html>
- Previous message: [LLVMdev] Find function parameters
- Next message: [LLVMdev] Disable JIT and interpret code instead in VMKit
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]