// Dual licensed under the terms of the MIT X11 or GNU GPL
//
// Copyright 2007-2008 Novell, Inc
+// Copyright 2011 Xamarin Inc
//
#if STATIC
// A list of Parameters (explicitly typed parameters)
// An ImplicitLambdaParameter
//
- public LambdaExpression (bool isAsync, Location loc)
- : base (isAsync, loc)
- {
- }
-
public LambdaExpression (Location loc)
- : this (false, loc)
+ : base (loc)
{
}
{
return "lambda expression";
}
+
+ public override object Accept (StructuralVisitor visitor)
+ {
+ return visitor.Visit (this);
+ }
}
class LambdaMethod : AnonymousMethodBody
{
if (statement != null) {
statement.EmitStatement (ec);
- ec.Emit (OpCodes.Ret);
+ if (unwind_protect)
+ ec.Emit (OpCodes.Leave, ec.CreateReturnLabel ());
+ else {
+ ec.Emit (OpCodes.Ret);
+ }
return;
}