Annotation Type IgnoreInWholeProgramInference
-
@Documented @Retention(RUNTIME) @Target({ANNOTATION_TYPE,FIELD}) public @interface IgnoreInWholeProgramInferenceThis annotation can be used two ways:1. As a meta-annotation indicating that an annotation type prevents whole-program inference. For example, if the definition of
@Injectis meta-annotated with@IgnoreInWholeProgramInference:
@IgnoreInWholeProgramInference
@interface Inject {}
then no type qualifier will be inferred for any field annotated by@Inject.This is appropriate for fields that are set reflectively, so there are no calls in client code that type inference can learn from. Examples of qualifiers that should be meta-annotated with
@IgnoreInWholeProgramInferenceinclude@Inject,@Singleton, and@Option.2. As a field annotation indicating that no type qualifier will be inferred for the field it annotates.
See org.checkerframework.common.wholeprograminference.WholeProgramInferenceScenes#updateFromFieldAssignment
- See the Checker Framework Manual:
- Whole-program inference
ignores some code