We currently define Thread::as_Java_thread() as an instance method to convert from a Thread* to a JavaThread*. Other Thread conversions have opted for a cast-style approach e.g.
static WorkerThread::cast(Thread* _this);
static CompilerThread::cast(Thread* _this);
we should look at doing JavaThread conversions in the same way for consistency.
This also helps remove Thread's knowledge of its subtypes from its API.
static WorkerThread::cast(Thread* _this);
static CompilerThread::cast(Thread* _this);
we should look at doing JavaThread conversions in the same way for consistency.
This also helps remove Thread's knowledge of its subtypes from its API.
- relates to
-
JDK-8267916 Adopt cast notation for CompilerThread conversions
-
- Resolved
-
-
JDK-8268164 Adopt cast notation for WorkerThread conversions
-
- Resolved
-