Currently, every type system needs to include, in its annotated libraries,
a conservative annotation for reflection methods such as
java.lang.reflect.Method.invoke(Object...)
java.lang.reflect.InvocationHandler.invoke(Object, Method,
java.lang.Object[])
javax.xml.ws.spi.Invoker(Method, Object...)
This is error-prone: the designer of a type system may forget this detail. It
would be nicer to prevent this error from occurring, and then reflection would
not be a source of unsoundness in the Checker Framework.
I propose to define a method annotation @ReflectionMethod, and to write it on
the above methods in the annotated JDK.
The Checker Framework will treat any method annotated with @ReflectionMethod as
having maximally-conservative annotations.
Original issue reported on code.google.com by michael.ernst@gmail.com on 28 Aug 2014 at 8:09
Original issue reported on code.google.com by
michael.ernst@gmail.com
on 28 Aug 2014 at 8:09