1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-06-06 17:26:01 +02:00

Bug 443120 - Source lookup should be able to find source file without

participant

Change-Id: I56fc43dca341705b67f699764b14e8beb7f9e437
Reviewed-on: https://git.eclipse.org/r/32725
Tested-by: Hudson CI
Reviewed-by: Elena Laskavaia <elaskavaia.cdt@gmail.com>
This commit is contained in:
Alena Laskavaia 2014-09-02 12:57:07 -04:00 committed by Elena Laskavaia
parent 096fae2b3e
commit a5c99092dd

View file

@ -18,6 +18,7 @@ import java.util.List;
import java.util.Map;
import java.util.concurrent.ExecutionException;
import org.eclipse.cdt.debug.core.sourcelookup.AbsolutePathSourceContainer;
import org.eclipse.cdt.dsf.concurrent.ConfinedToDsfExecutor;
import org.eclipse.cdt.dsf.concurrent.DataRequestMonitor;
import org.eclipse.cdt.dsf.concurrent.DsfExecutor;
@ -95,7 +96,10 @@ public class DsfSourceLookupParticipant implements ISourceLookupParticipant {
} else {
results = new ArrayList<Object>();
}
ISourceContainer[] containers = getSourceContainers();
ISourceContainer[] containers = getSourceContainers();
// if there is no containers, we can default to absolute path, since we should be able resolve file by absolute path
if (containers.length == 0)
containers = new ISourceContainer[] { new AbsolutePathSourceContainer() };
for (int i = 0; i < containers.length; i++) {
try {
ISourceContainer container = containers[i];