Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 336123 - DefinitionFinder2 doesn't find function definitions
Summary: DefinitionFinder2 doesn't find function definitions
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-refactoring (show other bugs)
Version: 8.0   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 8.0   Edit
Assignee: Sergey Prigogin CLA
QA Contact: Emanuel Graf CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 292851
  Show dependency tree
 
Reported: 2011-02-02 13:13 EST by Marc-André Laperle CLA
Modified: 2011-02-10 09:12 EST (History)
2 users (show)

See Also:


Attachments
DefinitionFinder function testcase (3.62 KB, patch)
2011-02-02 13:13 EST, Marc-André Laperle CLA
eclipse.sprigogin: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Marc-André Laperle CLA 2011-02-02 13:13:21 EST
Created attachment 188175 [details]
DefinitionFinder function testcase

Example:

//A.h
#ifndef A_H_
#define A_H_

void foo();

#endif

//A.cpp
#include "A.h"

void foo()
{

}

It seems CPPVisitor.CollectDeclarationsAction.isDeclarationsBinding is comparing a PDOMCPPFunction (obtained with adaptBinding) and a CPPFunction (from the AST).

Using DefinitionFinder on a function is useful for implement method.

Attached is a simple test case to illustrate the problem.
Comment 1 Sergey Prigogin CLA 2011-02-04 21:51:19 EST
Fixed in HEAD > 20110204.