Skip to content

Commit

Permalink
Fix for issue #224 and #232: NPE in stub Groovy annotation
Browse files Browse the repository at this point in the history
  • Loading branch information
eric-milles committed Dec 5, 2016
1 parent 8abd6b1 commit df0c92d
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ public TypeBinding resolveType(BlockScope scope) {
// allow the Groovy annotation to show in Javadoc
// TODO: Does this cause unanticipated side effects?
this.compilerAnnotation = scope.environment().createAnnotation(
(ReferenceBinding) this.resolvedType, computeElementValuePairs());
(ReferenceBinding) this.resolvedType, Binding.NO_ELEMENT_VALUE_PAIRS);
} else {
scope.problemReporter().typeMismatchError(typeBinding, scope.getJavaLangAnnotationAnnotation(), this.type, null);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ public TypeBinding resolveType(BlockScope scope) {
// allow the Groovy annotation to show in Javadoc
// TODO: Does this cause unanticipated side effects?
this.compilerAnnotation = scope.environment().createAnnotation(
(ReferenceBinding) this.resolvedType, computeElementValuePairs());
(ReferenceBinding) this.resolvedType, Binding.NO_ELEMENT_VALUE_PAIRS);
} else {
scope.problemReporter().typeMismatchError(typeBinding, scope.getJavaLangAnnotationAnnotation(), this.type, null);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -725,7 +725,7 @@ public TypeBinding resolveType(BlockScope scope) {
// allow the Groovy annotation to show in Javadoc
// TODO: Does this cause unanticipated side effects?
this.compilerAnnotation = scope.environment().createAnnotation(
(ReferenceBinding) this.resolvedType, computeElementValuePairs());
(ReferenceBinding) this.resolvedType, Binding.NO_ELEMENT_VALUE_PAIRS);
} else {
scope.problemReporter().typeMismatchError(typeBinding, scope.getJavaLangAnnotationAnnotation(), this.type, null);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -804,7 +804,7 @@ public TypeBinding resolveType(BlockScope scope) {
// allow the Groovy annotation to show in Javadoc
// TODO: Does this cause unanticipated side effects?
this.compilerAnnotation = scope.environment().createAnnotation(
(ReferenceBinding) this.resolvedType, computeElementValuePairs());
(ReferenceBinding) this.resolvedType, Binding.NO_ELEMENT_VALUE_PAIRS);
} else {
scope.problemReporter().typeMismatchError(typeBinding, scope.getJavaLangAnnotationAnnotation(), this.type, null);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -804,7 +804,7 @@ public TypeBinding resolveType(BlockScope scope) {
// allow the Groovy annotation to show in Javadoc
// TODO: Does this cause unanticipated side effects?
this.compilerAnnotation = scope.environment().createAnnotation(
(ReferenceBinding) this.resolvedType, computeElementValuePairs());
(ReferenceBinding) this.resolvedType, Binding.NO_ELEMENT_VALUE_PAIRS);
} else {
scope.problemReporter().notAnnotationType(typeBinding, this.type);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -803,7 +803,7 @@ public TypeBinding resolveType(BlockScope scope) {
// allow the Groovy annotation to show in Javadoc
// TODO: Does this cause unanticipated side effects?
this.compilerAnnotation = scope.environment().createAnnotation(
(ReferenceBinding) this.resolvedType, computeElementValuePairs());
(ReferenceBinding) this.resolvedType, Binding.NO_ELEMENT_VALUE_PAIRS);
} else {
scope.problemReporter().notAnnotationType(typeBinding, this.type);
}
Expand Down

0 comments on commit df0c92d

Please sign in to comment.