Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Thread.stop() deprecated almost 25 years back but never removed - Why?

I could not find any documentation, reference or rationale for this.

Thread.stop() has been deprecated since 1.2, almost quarter of a century back but has never been removed from JDK

Why?

    @Deprecated(since="1.2", forRemoval=true)
     public final void stop() {
like image 588
Ironluca Avatar asked Oct 30 '25 23:10

Ironluca


1 Answers

Because there could be old code that still executes it. Removing it would cause old code to no longer compile.

Sun and now Oracle have been cautious in terms of removing code that could require recompiles. Though lately they are slowly cleaning these things up. Because as you state, decades have passed, so its time.

like image 70
AminM Avatar answered Nov 01 '25 14:11

AminM