Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Show Callees and virtual functions.

 Hello,
thak you for your work!
I have switched to Eclipse+CDT after release of CDT5 as my main IDE. Support of C++ is very good.

But there are still some issues.

I am using "Open Call Hierarchy" very frequently, it works almost always correctly for "Show Callers". But for "Show Callees" there is definitely problem with virtual functions. Consider the following code:

class Base {
public:
  Base() {}
  virtual ~Base() {}
  virtual void First() {}
  virtual void Second() {}
};

class Derived: public Base {
public:
  Derived() {}
  virtual ~Derived() {}
  virtual void First() {}
  virtual void Second() {}
};

void func(Base *base) {
  base->First();
  base->Second();
}

int main() {
  Derived derived;
  func(&derived);
	return 0;
}

Select "Open Call Hierarchy" for main() and switch to "Show Calees" mode.
Expand the node main()->func(Base*)->Base::Second().
There are two sons of the node: Base::First() and Derived::First().
But there should be Base::Second() and Derived::Second().

I am using CDT:
  Version: 5.0.0.200806171202
  Build id: 200806171202



Back to the top