1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00
This commit is contained in:
Alain Magloire 2003-10-01 14:18:13 +00:00
parent fc7419740e
commit 8a05fb1f3a

View file

@ -113,6 +113,7 @@ public class BinaryElement extends CElement implements IBinaryElement, ISourceMa
}
}
} else {
// TODO-model: handle non-absolute paths when finding source files
// ??? assert()
path = new Path("");
}
@ -121,7 +122,10 @@ public class BinaryElement extends CElement implements IBinaryElement, ISourceMa
ICProject cproject = getCProject();
SourceMapper mapper = mgr.getSourceMapper(cproject);
if (mapper != null) {
tu = mapper.findTranslationUnit(path.lastSegment());
String lastSegment = path.lastSegment();
if (lastSegment != null) {
tu = mapper.findTranslationUnit(lastSegment);
}
}
}
}