Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mark System.Threading.Thread ResetAbort as Obsolete #41925

Closed
mdh1418 opened this issue Sep 7, 2020 · 2 comments · Fixed by #42228
Closed

Mark System.Threading.Thread ResetAbort as Obsolete #41925

mdh1418 opened this issue Sep 7, 2020 · 2 comments · Fixed by #42228
Labels
api-approved API was approved in API review, it can be implemented area-System.Threading
Milestone

Comments

@mdh1418
Copy link
Member

mdh1418 commented Sep 7, 2020

It was recognized in #41892 that System.Threading.Thread ResetAbort throws PlatformNotSupportedException everywhere and should be marked as Obsolete.

@mdh1418 mdh1418 added this to the 6.0.0 milestone Sep 7, 2020
@Dotnet-GitSync-Bot Dotnet-GitSync-Bot added the untriaged New issue has not been triaged by the area owner label Sep 7, 2020
@GrabYourPitchforks GrabYourPitchforks added the api-ready-for-review API is ready for review, it is NOT ready for implementation label Sep 7, 2020
@GrabYourPitchforks
Copy link
Member

I've marked this ready for review since it's very straightforward. Recommend reusing the SYSLIB0006 (Thread.Abort is obsolete) code for this.

@marek-safar marek-safar removed the untriaged New issue has not been triaged by the area owner label Sep 8, 2020
@terrajobst
Copy link
Member

terrajobst commented Sep 8, 2020

Video

  • We believe it makes sense to reuse the existing diagnostic ID
namespace System.Threading
{
    public sealed class Thread
    {
        // Obsoleted in .NET 5:
        //[Obsolete(DiagnosticId = "SYSLIB0006")]
        //public void Abort();
        //[Obsolete(DiagnosticId = "SYSLIB0006")]
        //public void Abort(object stateInfo);
        [Obsolete(DiagnosticId = "SYSLIB0006")]
        public static void ResetAbort();
    }
}

@terrajobst terrajobst added api-approved API was approved in API review, it can be implemented and removed api-ready-for-review API is ready for review, it is NOT ready for implementation labels Sep 8, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Dec 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
api-approved API was approved in API review, it can be implemented area-System.Threading
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants