Skip to content

Priority Queue in C#: port to .NET 10 and add Remove, DequeueEnqueue and Capacity examples - #2320

Merged
vladimir-pecanac-main merged 2 commits into
CodeMazeBlog:mainfrom
vladimir-pecanac-main:seo/68988-csharp-priority-queue
Oct 28, 2026
Merged

vladimir-pecanac-main merged 2 commits into
CodeMazeBlog:mainfrom
vladimir-pecanac-main:seo/68988-csharp-priority-queue

Conversation

@vladimir-pecanac-main

Copy link
Copy Markdown
Collaborator

Moves the PriorityQueueInCSharp sample from net6.0 to net10.0 with MSTest 4.5.1, Microsoft.NET.Test.Sdk 18.11.0 and coverlet.collector 10.1.0. Capacity reads now use the .NET 10 Capacity property instead of EnsureCapacity(0), asserts pass the expected value first, the comparer takes nullable parameters, Program.cs now calls its two demos so dotnet run prints the article's output, and test name typos are fixed. New tests cover EnqueueDequeue versus DequeueEnqueue, Remove with re-enqueueing, UnorderedItems order, a reversed comparer and a small lock-based SynchronizedHospitalQueue.

@vladimir-pecanac-main
vladimir-pecanac-main merged commit 956af32 into CodeMazeBlog:main Oct 28, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant