public override Delegate GetDelegateForInterpreter(CodeContext context, Type delegateType, bool forceWrapperMethod) { // For now, always return a compiled delegate (since yield is not implemented) lock (this) { if (_delegate == null) { FlowChecker.Check(this); _delegate = GetCompiledDelegate(context.ModuleContext.CompilerContext, delegateType, forceWrapperMethod); } return(_delegate); } }
public static void Check(CodeBlock block) { FlowChecker fc = new FlowChecker(block); fc.WalkNode(block); }