From 3e38a049542fe7a2b4ff07738292f865059cb3a1 Mon Sep 17 00:00:00 2001 From: martincostello Date: Thu, 11 Jul 2024 15:28:47 +0100 Subject: [PATCH] Use System.Threading.Lock Use `System.Threading.Lock` instead of an object to resolve `IDE0330` warning in .NET 9 preview 7. --- src/ProjectEuler/Puzzles/Puzzle014.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ProjectEuler/Puzzles/Puzzle014.cs b/src/ProjectEuler/Puzzles/Puzzle014.cs index 1b301a18..94a4ae39 100644 --- a/src/ProjectEuler/Puzzles/Puzzle014.cs +++ b/src/ProjectEuler/Puzzles/Puzzle014.cs @@ -13,7 +13,7 @@ public sealed class Puzzle014 : Puzzle /// private static readonly Dictionary _cache = new(1_000_000); - private static readonly object _lock = new(); + private static readonly System.Threading.Lock _lock = new(); /// public override string Question => "Which starting number, under one million, produces the longest chain?";