From a94f010ee3e7784eb063405a36926aa001c14ef3 Mon Sep 17 00:00:00 2001 From: Simon Potter Date: Tue, 1 May 2018 15:55:22 -0400 Subject: [PATCH] Remove unnecessary type and property instrumentation. --- .../Instrumentation/Instrumenter.cs | 25 ------------------- 1 file changed, 25 deletions(-) diff --git a/src/coverlet.core/Instrumentation/Instrumenter.cs b/src/coverlet.core/Instrumentation/Instrumenter.cs index a2e0e55ee..1387546d0 100644 --- a/src/coverlet.core/Instrumentation/Instrumenter.cs +++ b/src/coverlet.core/Instrumentation/Instrumenter.cs @@ -79,31 +79,6 @@ private void InstrumentType(TypeDefinition type) if (!method.CustomAttributes.Any(IsExcludeAttribute)) InstrumentMethod(method); } - - foreach (var property in type.Properties) - { - if (!property.CustomAttributes.Any(IsExcludeAttribute)) - InstrumentProperty(property); - } - - if (type.HasNestedTypes) - { - foreach (var nestedType in type.NestedTypes) - InstrumentType(nestedType); - } - } - - private void InstrumentProperty(PropertyDefinition property) - { - if (property.GetMethod != null && !property.GetMethod.IsAbstract) - { - InstrumentMethod(property.GetMethod); - } - - if (property.SetMethod != null && !property.SetMethod.IsAbstract) - { - InstrumentMethod(property.SetMethod); - } } private void InstrumentMethod(MethodDefinition method)