From b8f2d18adc4102829fba812262f5cd01557ed876 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20M=C3=BCller?= Date: Thu, 3 Apr 2025 08:42:22 +0200 Subject: [PATCH 1/2] init --- src/coverlet.core/Symbols/CecilSymbolHelper.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/coverlet.core/Symbols/CecilSymbolHelper.cs b/src/coverlet.core/Symbols/CecilSymbolHelper.cs index b5e40259c..a278c5da3 100644 --- a/src/coverlet.core/Symbols/CecilSymbolHelper.cs +++ b/src/coverlet.core/Symbols/CecilSymbolHelper.cs @@ -7,6 +7,7 @@ using System.Linq; using System.Runtime.CompilerServices; using System.Text.RegularExpressions; +using System.Threading.Tasks; using Coverlet.Core.Abstractions; using Coverlet.Core.Extensions; @@ -733,7 +734,7 @@ static bool CheckForSkipDisposal(List instructions, Instruction ins field.Equals(reloadedField) && instructions[i + 1].OpCode == OpCodes.Callvirt && instructions[i + 1].Operand is MethodReference method && - method.DeclaringType.FullName == "System.IAsyncDisposable" && + method.ReturnType.FullName == typeof(ValueTask).FullName && method.Name == "DisposeAsync") { isFollowedByDisposeAsync = true; @@ -755,7 +756,7 @@ static bool CheckForSkipDisposal(List instructions, Instruction ins instructions[currentIndex - 1].OpCode == OpCodes.Ldloc_3) && instructions[currentIndex + 2].OpCode == OpCodes.Callvirt && instructions[currentIndex + 2].Operand is MethodReference method && - method.DeclaringType.FullName == "System.IAsyncDisposable" && + method.ReturnType.FullName == typeof(ValueTask).FullName && method.Name == "DisposeAsync") { isFollowedByDisposeAsync = true; From a09046a09cececce348a588b7e54fbdcfeb85a4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20M=C3=BCller?= Date: Fri, 4 Apr 2025 01:17:10 +0200 Subject: [PATCH 2/2] update changelog + bump sdk --- Documentation/Changelog.md | 5 +++-- global.json | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Documentation/Changelog.md b/Documentation/Changelog.md index 54316af61..b78c5a295 100644 --- a/Documentation/Changelog.md +++ b/Documentation/Changelog.md @@ -7,10 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## Unreleased ### Fixed -- use `netstandard2.0` for _coverlet.collector_ and _coverlet.msbuild.tasks_ Packages´ +- Fix branchpoint exclusion for sdk 8.0.407 [#1741](https://github.com/coverlet-coverage/coverlet/issues/1741) +- Use `netstandard2.0` for _coverlet.collector_ and _coverlet.msbuild.tasks_ Packages´ ### Improvements -- use [xunit.v3](https://xunit.net/docs/getting-started/v3/whats-new) for tests and example code +- Use [xunit.v3](https://xunit.net/docs/getting-started/v3/whats-new) for tests and example code ## Release date 2024-01-20 diff --git a/global.json b/global.json index bd1052c7a..6dfc6666e 100644 --- a/global.json +++ b/global.json @@ -1,5 +1,5 @@ { "sdk": { - "version": "8.0.113" + "version": "8.0.407" } }