View | Details | Raw Unified | Return to bug 140318 | Differences between
and this patch

Collapse All | Expand All

(-)compiler/org/eclipse/jdt/internal/compiler/ast/Annotation.java (-5 / +1 lines)
Lines 224-244 Link Here
224
224
225
		if (this.compilerAnnotation != null)
225
		if (this.compilerAnnotation != null)
226
			return this.resolvedType;
226
			return this.resolvedType;
227
		boolean initializeCompilerAnnotation = true; // scope.compilerOptions().storeAnnotations;
228
		this.constant = Constant.NotAConstant;
227
		this.constant = Constant.NotAConstant;
229
		
228
		
230
		TypeBinding typeBinding = this.type.resolveType(scope);
229
		TypeBinding typeBinding = this.type.resolveType(scope);
231
		if (typeBinding == null) {
230
		if (typeBinding == null) {
232
			if (initializeCompilerAnnotation)
233
				this.compilerAnnotation = new AnnotationBinding(this);
234
			return null;
231
			return null;
235
		}
232
		}
236
		this.resolvedType = typeBinding;
233
		this.resolvedType = typeBinding;
237
		// ensure type refers to an annotation type
234
		// ensure type refers to an annotation type
238
		if (!typeBinding.isAnnotationType()) {
235
		if (!typeBinding.isAnnotationType()) {
239
			scope.problemReporter().typeMismatchError(typeBinding, scope.getJavaLangAnnotationAnnotation(), this.type);
236
			scope.problemReporter().typeMismatchError(typeBinding, scope.getJavaLangAnnotationAnnotation(), this.type);
240
			if (initializeCompilerAnnotation)
241
				this.compilerAnnotation = new AnnotationBinding(this);
242
			return null;
237
			return null;
243
		}
238
		}
244
239
Lines 302-307 Link Here
302
				pairs[i].resolveTypeExpecting(scope, null); // resilient
297
				pairs[i].resolveTypeExpecting(scope, null); // resilient
303
			}
298
			}
304
		}
299
		}
300
		boolean initializeCompilerAnnotation = true; // scope.compilerOptions().storeAnnotations;
305
		if (initializeCompilerAnnotation)
301
		if (initializeCompilerAnnotation)
306
			this.compilerAnnotation = new AnnotationBinding(this);
302
			this.compilerAnnotation = new AnnotationBinding(this);
307
		// recognize standard annotations ?
303
		// recognize standard annotations ?

Return to bug 140318