1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-24 01:15:29 +02:00

Bug 318130: Exception when extracting a function

https://bugs.eclipse.org/bugs/show_bug.cgi?id=318130
This commit is contained in:
Emanuel Graf 2010-07-06 12:04:01 +00:00
parent e846e27bc9
commit 0a81559841

View file

@ -202,7 +202,7 @@ public class NodeContainer {
}
public boolean isDeclarationInScope() {
if(declaration.toCharArray().length > 0) {
if(declaration != null && declaration.toCharArray().length > 0) {
int declOffset = declaration.getFileLocation().getNodeOffset();
return declOffset >= getStartOffset()
&& declOffset <= getEndOffset();