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 149457 Details for
Bug 292174
Indexer fast crashes with NPE if enclosing class definition is not available.
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
A patch fixing the issue.
eclipse-indexer.patch (text/plain), 2.67 KB, created by
Tobias Hahn
on 2009-10-13 13:58:30 EDT
(
hide
)
Description:
A patch fixing the issue.
Filename:
MIME Type:
Creator:
Tobias Hahn
Created:
2009-10-13 13:58:30 EDT
Size:
2.67 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.cdt.core >Index: parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPLinkage.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/all/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPLinkage.java,v >retrieving revision 1.135 >diff -u -r1.135 PDOMCPPLinkage.java >--- parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPLinkage.java 28 Jul 2009 14:06:44 -0000 1.135 >+++ parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPLinkage.java 13 Oct 2009 16:14:29 -0000 >@@ -905,9 +905,12 @@ > if (elaboratedSpecifier.isFriend()) { > pdomName.setIsFriendSpecifier(true); > PDOMName enclClassName= (PDOMName) pdomName.getEnclosingDefinition(); >- PDOMBinding enclClassBinding= enclClassName.getBinding(); >- if (enclClassBinding instanceof PDOMCPPClassType) { >- ((PDOMCPPClassType)enclClassBinding).addFriend(new PDOMCPPFriend(this, pdomName)); >+ if (enclClassName != null) >+ { >+ PDOMBinding enclClassBinding= enclClassName.getBinding(); >+ if (enclClassBinding instanceof PDOMCPPClassType) { >+ ((PDOMCPPClassType)enclClassBinding).addFriend(new PDOMCPPFriend(this, pdomName)); >+ } > } > } > } else if (parentNode instanceof ICPPASTFunctionDeclarator) { >@@ -917,9 +920,12 @@ > if (((ICPPASTDeclSpecifier)grandparentNode.getDeclSpecifier()).isFriend()) { > pdomName.setIsFriendSpecifier(true); > PDOMName enclClassName= (PDOMName) pdomName.getEnclosingDefinition(); >- PDOMBinding enclClassBinding= enclClassName.getBinding(); >- if (enclClassBinding instanceof PDOMCPPClassType) { >- ((PDOMCPPClassType)enclClassBinding).addFriend(new PDOMCPPFriend(this, pdomName)); >+ if (enclClassName != null) >+ { >+ PDOMBinding enclClassBinding= enclClassName.getBinding(); >+ if (enclClassBinding instanceof PDOMCPPClassType) { >+ ((PDOMCPPClassType)enclClassBinding).addFriend(new PDOMCPPFriend(this, pdomName)); >+ } > } > } > } >@@ -965,10 +971,13 @@ > } > if (pdomName.isFriendSpecifier()) { > PDOMName enclClassName= (PDOMName) pdomName.getEnclosingDefinition(); >- PDOMBinding enclClassBinding= enclClassName.getBinding(); >- if (enclClassBinding instanceof PDOMCPPClassType) { >- PDOMCPPClassType ownerClass = (PDOMCPPClassType)enclClassBinding; >- ownerClass.removeFriend(pdomName); >+ if (enclClassName != null) >+ { >+ PDOMBinding enclClassBinding= enclClassName.getBinding(); >+ if (enclClassBinding instanceof PDOMCPPClassType) { >+ PDOMCPPClassType ownerClass = (PDOMCPPClassType)enclClassBinding; >+ ownerClass.removeFriend(pdomName); >+ } > } > } > }
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
Flags:
mschorn.eclipse
:
iplog+
Actions:
View
|
Diff
Attachments on
bug 292174
: 149457