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 51670 Details for
Bug 152961
[compiler] Private inner interface is "never used locally"
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Proposed patch
v00.txt (text/plain), 1.76 KB, created by
Frederic Fusier
on 2006-10-10 06:41:09 EDT
(
hide
)
Description:
Proposed patch
Filename:
MIME Type:
Creator:
Frederic Fusier
Created:
2006-10-10 06:41:09 EDT
Size:
1.76 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.core >Index: compiler/org/eclipse/jdt/internal/compiler/ast/ASTNode.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/ast/ASTNode.java,v >retrieving revision 1.74 >diff -u -r1.74 ASTNode.java >--- compiler/org/eclipse/jdt/internal/compiler/ast/ASTNode.java 4 Oct 2006 10:07:21 -0000 1.74 >+++ compiler/org/eclipse/jdt/internal/compiler/ast/ASTNode.java 10 Oct 2006 10:44:14 -0000 >@@ -396,9 +396,20 @@ > > ReferenceBinding refType = (ReferenceBinding) type; > >- if ((refType.isPrivate() /*|| refType.isLocalType()*/) && !scope.isDefinedInType(refType)) { >- // ignore cases where type is used from within inside itself >- ((ReferenceBinding)refType.erasure()).modifiers |= ExtraCompilerModifiers.AccLocallyUsed; >+ // Need to to recurse through all enclosing types while setting ExtraCompilerModifiers.AccLocallyUsed bit >+ // See bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=152961 >+ ReferenceBinding enclosingType = refType; >+ while (enclosingType != null) { >+ if ((enclosingType.modifiers & ExtraCompilerModifiers.AccLocallyUsed) != 0) { >+ // this flag has been already set for upper enclosing types => end now >+ break; >+ } >+ // TODO Setup this flag even when not private would avoid to recurse twice in same enclosing types... >+ if (enclosingType.isPrivate() && !scope.isDefinedInType(enclosingType)) { >+ // ignore cases where type is used from within inside itself >+ ((ReferenceBinding) enclosingType.erasure()).modifiers |= ExtraCompilerModifiers.AccLocallyUsed; >+ } >+ enclosingType = enclosingType.enclosingType(); > } > > if (refType.hasRestrictedAccess()) {
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 152961
:
51670