PolySharp icon indicating copy to clipboard operation
PolySharp copied to clipboard

Add new `System.Diagnostics.UnreachableException` polyfill

Open 0xced opened this issue 2 years ago • 3 comments

Closes #60

Additional context

The System.Diagnostics.UnreachableException.cs file was not actually auto-generated (see #88).

Also, only the English localization was considered for the exception message.

0xced avatar Nov 08 '23 16:11 0xced

Is this ever going to be provided?

We are still running our own implementation of UnreachableException, but would prefer to receive it through PolySharp.

ristogod avatar Nov 22 '24 15:11 ristogod

I just rebased on develop with a few improvements.

  • Addressed feedback from @cremor
    • Added the ExcludeFromCodeCoverage attribute
    • Made the UnreachableException class internal instead of public
  • Added mention of this new class in the README

0xced avatar Nov 22 '24 15:11 0xced

Is there anything holding this pull request @Sergio0694? It looks like several people are interested in it.

0xced avatar Feb 05 '25 20:02 0xced

I see there's some recent activity here in #127. Please don't forget about this pull request too if you're goint to release a new version of PolySharp. 😉

0xced avatar Jun 27 '25 07:06 0xced

UnreachableException is available in .NET 8 and .NET 9, the only .NET versions which are still supported.

But it still makes sense when targeting .NET Standard.

Any chance to get this merged, @Sergio0694?

0xced avatar Oct 21 '25 22:10 0xced