Skip to content

Commit

Permalink
ensure interface change is backwards compatible
Browse files Browse the repository at this point in the history
  • Loading branch information
hcoles committed Jun 16, 2023
1 parent 7bdadd8 commit cc3ae8e
Showing 1 changed file with 15 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,28 @@ default MethodVisitor create(MutationContext context,
return null;
}


@Deprecated
default AnnotationVisitor createForAnnotation(NoMethodContext context, AnnotationInfo annotationInfo, AnnotationVisitor next) {
return createForAnnotation((BasicContext) context, annotationInfo, next);
}
default AnnotationVisitor createForAnnotation(BasicContext context, AnnotationInfo annotationInfo, AnnotationVisitor next) {
return null;
}

default boolean skipAnnotation(BasicContext nonMethodContext, AnnotationInfo annotationInfo) {
@Deprecated
default boolean skipAnnotation(NoMethodContext context, AnnotationInfo annotationInfo) {
return skipAnnotation((BasicContext) context, annotationInfo);
}

default boolean skipAnnotation(BasicContext context, AnnotationInfo annotationInfo) {
return false;
}

@Deprecated
default FieldVisitor createForField(NoMethodContext context, FieldInfo fieldInfo, FieldVisitor fieldVisitor) {
return createForField((BasicContext) context, fieldInfo, fieldVisitor);
}

default FieldVisitor createForField(BasicContext context, FieldInfo fieldInfo, FieldVisitor fieldVisitor) {
return null;
}
Expand Down

0 comments on commit cc3ae8e

Please sign in to comment.