Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 308744

Summary: Breakpoints not triggered in files with identical names
Product: [Tools] CDT Reporter: Victor Zverovich <victor.zverovich>
Component: cdt-debugAssignee: cdt-debug-inbox <cdt-debug-inbox>
Status: RESOLVED DUPLICATE QA Contact: Ken Ryall <ken.ryall>
Severity: normal    
Priority: P3 CC: elaskavaia.cdt, pawel.1.piech
Version: 0 DD 1.1   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard:
Attachments:
Description Flags
Test project that can be used to reproduce the problem none

Description Victor Zverovich CLA 2010-04-11 03:09:47 EDT
Build Identifier: 3.5.1

If the C++ project contains identically named files in different directories then the breakpoints are only triggered in one of the file. In other files the breakpoints either unresolved or even worse - resolved but not triggered which is very confusing.
Probably the default behaviour should be to use not only filenames but also directory components when setting the breakpoints in the debugger.

Reproducible: Always

Steps to Reproduce:
1. Create a new C++ project with the following contents:
a/test.cpp:
int TestA()
{
    return 0;
}

b/test.cpp
int TestB()
{
    return 0;
}

main.cpp:
int TestA();
int TestB();

int main()
{
    TestA();
    TestB();
    return 0;
}

2. Put breakpoints in TestA and TestB functions.
3. Start the debugger and observe that the breakpoint in TestB is not triggered.
Comment 1 Victor Zverovich CLA 2010-04-11 03:10:59 EDT
Build id: M20090917-0800
Eclipse CDT 6.0.2
Comment 2 Victor Zverovich CLA 2010-04-11 03:13:50 EDT
Created attachment 164483 [details]
Test project that can be used to reproduce the problem
Comment 3 Elena Laskavaia CLA 2010-04-11 14:18:02 EDT
Duplicate. Use option "Use full file name for breakpoint" in Debug tab.

*** This bug has been marked as a duplicate of bug 220045 ***