| Summary: | PDOM missing information about overloaded methods | ||
|---|---|---|---|
| Product: | [Tools] CDT | Reporter: | Jason Montojo <jason.montojo> |
| Component: | cdt-core | Assignee: | Project Inbox <cdt-core-inbox> |
| Status: | RESOLVED DUPLICATE | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | ||
| Version: | 4.0 | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Windows XP | ||
| Whiteboard: | |||
When a method is overloaded, the PDOM captures a subset of the information about all the methods. For example, given this code: class Class1 { public: void f(); void f(int i); }; Class1::f() { } Class1::f(int i) { } int main() { Class1 c; c.f(1); c.f(); return 0; } 1. Class1::f resolves to only 1 IBinding 2. The IBinding for Class1::f has parameters for only 1 definition of f() 3. The IBinding for Class1::f has 2 references in the PDOM 4. The IBinding for Class1::f has 4 declarations in the PDOM 5. The IBinding for Class1::f has 2 definitions in the PDOM So the references, declarations, and definitions are being counted across all variants of f(), but the IBinding points to one specific variant. This doesn't affect the C/C++ editor's Open Declaration/Definition feature, but it does affect Declarations->Workspace, References->Workspace and friends.