File tree 2 files changed +3
-20
lines changed
src/java.base/share/classes/java/lang
test/jdk/java/lang/Thread
2 files changed +3
-20
lines changed Original file line number Diff line number Diff line change @@ -2011,22 +2011,6 @@ public static int enumerate(Thread[] tarray) {
2011
2011
return currentThread ().getThreadGroup ().enumerate (tarray );
2012
2012
}
2013
2013
2014
- /**
2015
- * Throws {@code UnsupportedOperationException}.
2016
- *
2017
- * @return nothing
2018
- *
2019
- * @deprecated This method was originally designed to count the number of
2020
- * stack frames but the results were never well-defined and it
2021
- * depended on thread-suspension.
2022
- * This method is subject to removal in a future version of Java SE.
2023
- * @see StackWalker
2024
- */
2025
- @ Deprecated (since ="1.2" , forRemoval =true )
2026
- public int countStackFrames () {
2027
- throw new UnsupportedOperationException ();
2028
- }
2029
-
2030
2014
/**
2031
2015
* Waits at most {@code millis} milliseconds for this thread to terminate.
2032
2016
* A timeout of {@code 0} means to wait forever.
Original file line number Diff line number Diff line change 1
1
/*
2
- * Copyright (c) 2022, Oracle and/or its affiliates. All rights reserved.
2
+ * Copyright (c) 2022, 2023, Oracle and/or its affiliates. All rights reserved.
3
3
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4
4
*
5
5
* This code is free software; you can redistribute it and/or modify it
23
23
24
24
/* @test
25
25
* @bug 8289610 8249627 8205132
26
- * @summary Test that Thread stop/suspend/resume/countStackFrames throw UOE
26
+ * @summary Test that Thread stop/suspend/resume throw UOE
27
27
* @run junit DegradedMethodsThrowUOE
28
28
*/
29
29
@@ -45,8 +45,7 @@ static Stream<Consumer<Thread>> ops() {
45
45
return Stream .<Consumer <Thread >>of (
46
46
Thread ::stop ,
47
47
Thread ::suspend ,
48
- Thread ::resume ,
49
- Thread ::countStackFrames
48
+ Thread ::resume
50
49
);
51
50
}
52
51
You can’t perform that action at this time.
0 commit comments