Bug 97402 Save Failed: org.eclipse.jdt.internal.compiler.ast.LocalDeclaration
Version: 3.1.0 Build id: I20050527-1300 (RC1) Steps to reproduce: 1.) Have a Class Foo like this: public class Foo { private static void foo() { @interface Bar { public String bar = "Hu"; } } } 2.) Save Actual Results: Error Dialog showing with the message: Save Failed: org.eclipse.jdt.internal.compiler.ast.LocalDeclaration Expected Results: No error Dialog Regards, Ben
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/CompilationUnitDocumentProvider.java
else
						stopCollectingProblems();
				}
			}
			private Object getAnnotations(Position position) {
				synchronized (getLockObject()) {
					return fReverseMap.get(position);
				}
			}
			/*
			 * @see AnnotationModel#addAnnotation(Annotation, Position, boolean)
			 */
			protected void addAnnotation(Annotation annotation, Position position, boolean fireModelChanged) throws BadLocationException {
				super.addAnnotation(annotation, position, fireModelChanged);
				synchronized (getLockObject()) {
					Object cached= fReverseMap.get(position);
					if (cached == null)
						fReverseMap.put(position, annotation);
					else if (cached instanceof List) {
						List list= (List) cached;
						list.add(annotation);
					} else if (cached instanceof Annotation) {
						List list= new ArrayList(2);
						list.add(cached);
						list.add(annotation);
						fReverseMap.put(position, list);
					}
				}
			}
			/*