• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //===-- main.cpp ------------------------------------------------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 
10 #include <stdio.h>
11 
12 class A
13 {
14 public:
15   static int getStaticValue();
16   int getMemberValue();
17   int a;
18 };
19 
getStaticValue()20 int A::getStaticValue()
21 {
22   return 5;
23 }
24 
getMemberValue()25 int A::getMemberValue()
26 {
27   return a;
28 }
29 
main()30 int main()
31 {
32   A my_a;
33 
34   my_a.a = 3;
35 
36   printf("%d\n", A::getStaticValue()); // Break at this line
37   printf("%d\n", my_a.getMemberValue());
38 }
39