Skip to content

Commit

Permalink
Code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
sakno committed Jan 6, 2025
1 parent dd60317 commit 3632413
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -560,7 +560,7 @@ private static MemberExpression[] CreateStateHolderType(Type returnType, bool us
builder.Add(type);
}

slots = builder.Build<MemberExpression>(sm.Build, out _);
slots = builder.Build(sm.Build, out _);
}

Debug.Assert(sm.StateMachine is not null);
Expand Down
9 changes: 4 additions & 5 deletions src/DotNext.Tests/Metaprogramming/LambdaTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -98,13 +98,12 @@ public static void SimpleAsyncLambda(bool usePooling)
}

[Theory]
[InlineData(false)]
[InlineData(true)]
public static void SimpleUntypedAsyncLambda(bool usePooling)
[InlineData(AsyncLambdaFlags.None)]
[InlineData(AsyncLambdaFlags.UseTaskPooling)]
public static void SimpleUntypedAsyncLambda(AsyncLambdaFlags flags)
{
var sumMethod = typeof(LambdaTests).GetMethod(nameof(Sum), BindingFlags.Static | BindingFlags.NonPublic | BindingFlags.DeclaredOnly);
var flags = usePooling ? AsyncLambdaFlags.UseTaskPooling : AsyncLambdaFlags.None;
var lambda = AsyncLambda(new[] { typeof(long), typeof(long) }, typeof(long), flags, fun =>
var lambda = AsyncLambda([typeof(long), typeof(long)], typeof(long), flags, fun =>
{
var (arg1, arg2) = fun;
var temp = DeclareVariable<long>("tmp");
Expand Down

0 comments on commit 3632413

Please sign in to comment.