Bug 82041 [misc] ClassFileEditor uses generic names for method arguments when source info is available in class file
Version: 3.1.0 Build id: 200412210800 When you open a class file that has no source attachment but has full debugging information the editor does not show the real names of method arguments. 1. Open a class file editor on a class file that does not have a source attachment but has local variable debugging info. 2. Notice that the method arguments have generic names "arg<n>" ClassFileEditor is not asking the class file reader to look in the method bodies for info. In ClassFileEditor#updateCodeView, change: int flags= IClassFileReader.FIELD_INFOS | IClassFileReader.METHOD_INFOS | IClassFileReader.SUPER_INTERFACES; to: int flags= IClassFileReader.FIELD_INFOS | IClassFileReader.METHOD_INFOS | IClassFileReader.METHOD_BODIES | IClassFileReader.SUPER_INTERFACES; It doesn't appear to parse all of the byte code of the method bodies so it shouldn't slow things down too much for large class files.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/ClassFileEditor.java
if (entry == null || root.getKind() != IPackageFragmentRoot.K_BINARY) {
					createLabel(composite, JavaEditorMessages.getFormattedString("SourceAttachmentForm.message.noSource", fFile.getElementName())); 
					return;
				}
				
				if (entry.getEntryKind() == IClasspathEntry.CPE_CONTAINER) {
					containerPath= entry.getPath();
					IClasspathEntry entry2= JavaModelUtil.getClasspathEntryToEdit(jproject, containerPath, root.getPath());
					if (entry2 == null) {
						IClasspathContainer container= JavaCore.getClasspathContainer(entry.getPath(), root.getJavaProject());							
						String containerName= container == null ? entry.getPath().toString() : container.getDescription();
						createLabel(composite, JavaEditorMessages.getFormattedString("SourceAttachmentForm.message.containerEntry", containerName));  
						return;
					}
					entry= entry2;
				}
				
				
				Button button;
				IPath path= entry.getSourceAttachmentPath();			
				if (path == null || path.isEmpty()) {			
					createLabel(composite, JavaEditorMessages.getFormattedString("SourceAttachmentForm.message.noSourceAttachment", root.getElementName())); 
					createLabel(composite, JavaEditorMessages.getString("SourceAttachmentForm.message.pressButtonToAttach")); 
					createLabel(composite, null);
					button= createButton(composite, JavaEditorMessages.getString("SourceAttachmentForm.button.attachSource"));		 
				} else {
					createLabel(composite, JavaEditorMessages.getFormattedString("SourceAttachmentForm.message.noSourceInAttachment", fFile.getElementName())); 
					createLabel(composite, JavaEditorMessages.getString("SourceAttachmentForm.message.pressButtonToChange")); 
					createLabel(composite, null);