Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 43484 Details for
Bug 145367
Failing to open a binary member leaves cache inconsistent
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Proposed patch and regression test
140879.txt (text/plain), 2.35 KB, created by
Jerome Lanneluc
on 2006-06-05 12:03:34 EDT
(
hide
)
Description:
Proposed patch and regression test
Filename:
MIME Type:
Creator:
Jerome Lanneluc
Created:
2006-06-05 12:03:34 EDT
Size:
2.35 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.core >Index: model/org/eclipse/jdt/internal/core/ClassFile.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/ClassFile.java,v >retrieving revision 1.124 >diff -u -r1.124 ClassFile.java >--- model/org/eclipse/jdt/internal/core/ClassFile.java 26 Apr 2006 10:31:32 -0000 1.124 >+++ model/org/eclipse/jdt/internal/core/ClassFile.java 31 May 2006 16:51:52 -0000 >@@ -11,6 +11,7 @@ > package org.eclipse.jdt.internal.core; > > import java.io.IOException; >+import java.util.HashMap; > import java.util.Map; > import java.util.zip.ZipEntry; > import java.util.zip.ZipFile; >@@ -95,6 +96,10 @@ > IType type = new BinaryType(this, simpleName(typeInfo.getName())); > info.setChildren(new IJavaElement[] {type}); > newElements.put(type, typeInfo); >+ >+ // Read children >+ ((ClassFileInfo) info).readBinaryChildren((HashMap) newElements, typeInfo); >+ > return true; > } > /** >#P org.eclipse.jdt.core.tests.model >Index: src/org/eclipse/jdt/core/tests/model/ExistenceTests.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/model/ExistenceTests.java,v >retrieving revision 1.22 >diff -u -r1.22 ExistenceTests.java >--- src/org/eclipse/jdt/core/tests/model/ExistenceTests.java 4 May 2006 09:33:14 -0000 1.22 >+++ src/org/eclipse/jdt/core/tests/model/ExistenceTests.java 31 May 2006 16:51:57 -0000 >@@ -64,6 +64,18 @@ > } > assertTrue("Should not be able to get underlying resource", gotException); > } >+public void testBinaryMethodAfterNonExistingMember() throws CoreException { >+ try { >+ IJavaProject project = createJavaProject("P", new String[] {}, new String[] {"JCL_LIB"}, ""); >+ IClassFile classFile = project.getPackageFragmentRoot(getExternalJCLPathString()).getPackageFragment("java.lang").getClassFile("Object.class"); >+ classFile.open(null); >+ IType type = classFile.getType(); >+ type.getMethod("foo", new String[0]).exists(); >+ assertTrue("Object.toString() should exist", type.getMethod("toString", new String[0]).exists()); >+ } finally { >+ deleteProject("P"); >+ } >+} > public void testClassFileInBinary() throws CoreException { > try { > this.createJavaProject("P", new String[] {"src"}, "bin");
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 145367
: 43484