Lines Matching refs:Function
132 /// CallExprAST - Expression class for function calls.
162 /// PrototypeAST - This class represents the "prototype" for a function,
164 /// of arguments the function takes).
172 Function *Codegen();
175 /// FunctionAST - This class represents a function definition itself.
183 Function *Codegen();
405 return ErrorP("Expected function name in prototype");
468 // Look this variable up in the function.
493 Function *CalleeF = TheModule->getFunction(Callee);
495 return ErrorV("Unknown function referenced");
519 Function *TheFunction = Builder.GetInsertBlock()->getParent();
522 // end of the function.
584 Function *TheFunction = Builder.GetInsertBlock()->getParent();
654 Function *PrototypeAST::Codegen() {
655 // Make the function type: double(double,double) etc.
661 Function *F = Function::Create(FT, Function::ExternalLinkage, Name, TheModule);
672 ErrorF("redefinition of function");
678 ErrorF("redefinition of function with different # args");
685 for (Function::arg_iterator AI = F->arg_begin(); Idx != Args.size();
696 Function *FunctionAST::Codegen() {
699 Function *TheFunction = Proto->Codegen();
708 // Finish off the function.
714 // Optimize the function.
720 // Error reading body, remove function.
733 if (Function *LF = F->Codegen()) {
734 fprintf(stderr, "Read function definition:");
745 if (Function *F = P->Codegen()) {
756 // Evaluate a top-level expression into an anonymous function.
758 if (Function *LF = F->Codegen()) {
759 // JIT the function, returning a function pointer.
763 // can call it as a native function.