summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/commands/expression/call-overridden-method/main.cpp
blob: 712c374eefd9f28c9094d967004656ffdb5c0a13 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
class Base {
public:
  virtual ~Base() {}
  virtual int foo() { return 1; }
};

class Derived : public Base {
public:
  virtual int foo() { return 2; }
};

int main() {
  Base realbase;
  Derived d;
  Base *b = &d;
  return 0; // Set breakpoint here
}
OpenPOWER on IntegriCloud