Skip to content

Commit

Permalink
Remove commented vestigial code
Browse files Browse the repository at this point in the history
  • Loading branch information
extraes committed Dec 25, 2024
1 parent f574321 commit 7272bdf
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions Il2CppInterop.Generator/Passes/Pass61ImplementAwaiters.cs
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,7 @@ public static void DoPass(RewriteGlobalContext context)
.Include(interopOnCompleted);
var cloneResult = cloner.Clone();

// Established that INotifyCompletion.OnCompleted is implemented, & interop method is defined, now create the .NET interface implementation method that jumps to the proxy
//var onCompletedAttr = MethodAttributes.Public | MethodAttributes.Final | MethodAttributes.Virtual | MethodAttributes.HideBySig | MethodAttributes.NewSlot;
//var sig = MethodSignature.CreateInstance(voidRef, [actionUntypedRef.Value.ToTypeSignature()]);
//var proxyOnCompleted = new MethodDefinition(onCompletedContext.NewMethod.Name, onCompletedAttr, sig);

// Established that INotifyCompletion.OnCompleted is implemented, & interop method is defined, now clone it to create the .NET interface implementation method that jumps straight to it
var proxyOnCompleted = (MethodDefinition)cloneResult.ClonedMembers.Single();
proxyOnCompleted.Signature!.ParameterTypes[0] = actionUntypedRef.Value.ToTypeSignature();
var parameter = proxyOnCompleted.Parameters[0].GetOrCreateDefinition();
Expand Down

0 comments on commit 7272bdf

Please sign in to comment.