Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions SexyProxy/Emit/EmitProxyTypeFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ public Type CreateProxyType(Type sourceType)
il.Emit(OpCodes.Ldsfld, propertyInfoField); // Load the PropertyInfo onto the stack
il.Emit(OpCodes.Call, invocationHandlerIsHandlerActive); // Call InvocationHandler.IsHandlerActive and leave the bool result on the stack
il.Emit(OpCodes.Brtrue, notOptedOut); // If they didn't opt out (returned true), jump to the normal interception logic below
ImplementOptOut(il, methodInfo, proceedCall, isIntf, target); // They opted out, so do an implicit (and efficient) equivalent of proceed
ImplementOptOut(il, methodInfo, proceedCall, target); // They opted out, so do an implicit (and efficient) equivalent of proceed
il.MarkLabel(notOptedOut);

// Load handler
Expand Down Expand Up @@ -294,7 +294,7 @@ public Type CreateProxyType(Type sourceType)
return proxyType;
}

private void ImplementOptOut(ILGenerator il, MethodInfo methodInfo, OpCode proceedCall, bool isIntf, FieldBuilder target)
private void ImplementOptOut(ILGenerator il, MethodInfo methodInfo, OpCode proceedCall, FieldBuilder target)
{
var parameterInfos = methodInfo.GetParameters();

Expand Down