Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 339475 - Template constructor name resolves to wrong binding
Summary: Template constructor name resolves to wrong binding
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-parser (show other bugs)
Version: 8.0   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: 8.0   Edit
Assignee: Markus Schorn CLA
QA Contact: Markus Schorn CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-10 03:37 EST by Lukas Felber CLA
Modified: 2011-06-25 00:42 EDT (History)
3 users (show)

See Also:


Attachments
the eclipse project (16.78 KB, application/zip)
2011-03-10 03:38 EST, Lukas Felber CLA
no flags Details
testcase + fix (2.11 KB, patch)
2011-03-28 11:38 EDT, Markus Schorn CLA
mschorn.eclipse: iplog-
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Lukas Felber CLA 2011-03-10 03:37:43 EST
Build Identifier: M20100909-0800

When resolving an implicit constructor name, the returned binding points to the wrong constructor.

Reproducible: Always

Steps to Reproduce:
1. import the attached project
2. open main.cpp
3. ctrl+clicking on "iFive" resolves to the constructor of "Templ<int, length>" instead of the more specific definition "Templ<int, 5>"

interesting is, that ctrl+clicking on "Templ<int, 5>" in main resolves to the correct definition.
another hint: when copying all template specifications directly into main.cpp and removing the includes, the resolution works correctly.
Comment 1 Lukas Felber CLA 2011-03-10 03:38:35 EST
Created attachment 190829 [details]
the eclipse project
Comment 2 Markus Schorn CLA 2011-03-28 11:38:15 EDT
Created attachment 192015 [details]
testcase + fix
Comment 3 Markus Schorn CLA 2011-03-28 11:39:24 EDT
Fixed in 8.0.
Comment 5 Marc-André Laperle CLA 2011-06-25 00:42:44 EDT
Looks like this was fixed.