Fix nested functions.

My last patch was a little over-zealous in passing `undef`, it always passed
`undef` to inner functions expecting a single context frame.
This commit is contained in:
Frits van Bommel
2009-04-17 13:50:01 +02:00
parent 0262a6ec8f
commit 46565f1adc
3 changed files with 40 additions and 33 deletions

View File

@@ -46,7 +46,9 @@ struct IrFunction : IrBase
llvm::Value* nestedVar; // nested var alloca
const llvm::StructType* frameType; // type of nested context (not for -nested-ctx=array)
unsigned depth; // number of enclosing functions with variables accessed by nested functions
// number of enclosing functions with variables accessed by nested functions
// (-1 if neither this function nor any enclosing ones access variables from enclosing functions)
int depth;
llvm::Value* _arguments;
llvm::Value* _argptr;