| 1 | struct A { |
|---|---|
| 2 | public: |
| 3 | static int getStaticValue() { return 5; } |
| 4 | int getMemberValue() { return a; } |
| 5 | int a; |
| 6 | }; |
| 7 | |
| 8 | int main() |
| 9 | { |
| 10 | A a; |
| 11 | a.a = 3; |
| 12 | return A::getStaticValue() + a.getMemberValue(); // Break here |
| 13 | } |
| 14 |
| 1 | struct A { |
|---|---|
| 2 | public: |
| 3 | static int getStaticValue() { return 5; } |
| 4 | int getMemberValue() { return a; } |
| 5 | int a; |
| 6 | }; |
| 7 | |
| 8 | int main() |
| 9 | { |
| 10 | A a; |
| 11 | a.a = 3; |
| 12 | return A::getStaticValue() + a.getMemberValue(); // Break here |
| 13 | } |
| 14 |