ccls/foo/b.cc

18 lines
196 B
C++
Raw Normal View History

2017-04-19 04:58:39 +00:00
struct Parent {
virtual void Method() = 0;
};
struct Derived : public Parent {
void Method() override {}
};
2017-04-15 04:56:51 +00:00
2017-04-19 04:58:39 +00:00
void Caller() {
Derived d;
Parent* p = &d;
2017-04-15 04:56:51 +00:00
2017-04-19 04:58:39 +00:00
p->Method();
d->Method();
}