public GeneratedVariable LoadValueAtIndex(Type objectType, MethodBodyContext context, int index) { var variable = context.CreateVariable(objectType); actions.Add(new LoadValueAtIndexAction(method, this, index)); actions.Add(new VariableAssignmentAction(() => method.MethodBuilder(), variable.LocalIndex)); return(variable); }
public virtual void WithBody(Action <MethodBodyContext> nestedClosure) { var context = new MethodBodyContext(GeneratedMethod, typeGenerationContext, this); nestedClosure(context); }
public GeneratedDelegate(MethodBodyContext context, GeneratedMethod method, DelegateGenerator generator) { this.context = context; this.method = method; this.generator = generator; }
public DelegateBodyContext(MethodBodyContext context, DelegateGenerator generator) { this.context = context; this.generator = generator; }