-
Type:
Sub-task
-
Resolution: Delivered
-
Priority:
P4
-
Affects Version/s: 22
-
Component/s: core-libs
`sun.reflect.ReflectionFactory::newConstructorForSerialization` is reimplemented with method handles.
When `newConstructorForSerialization(C.class, ctor)` is called with a constructor whose declaring class is not a superclass of `C`, the old implementation returned an ill-formed constructor such that if `newInstance` is invoked, the behavior is unspecified. The new implementation will throw an `UnsupportedOperationException` instead, to fail fast.
When `newConstructorForSerialization(C.class, ctor)` is called with a constructor whose declaring class is not a superclass of `C`, the old implementation returned an ill-formed constructor such that if `newInstance` is invoked, the behavior is unspecified. The new implementation will throw an `UnsupportedOperationException` instead, to fail fast.