• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #include <stdio.h>
2 
inc(int a)3 int inc(int a) {
4   return a + 1;
5 }
6 
main()7 int main() {
8   printf("%p\n", inc);
9   return 0;
10 }
11 
12 // RUN: rm -rf %t && mkdir -p %t
13 // RUN: cp %s %t/
14 // RUN: cp %p/Inputs/print_context.o %t
15 // RUN: cd %t
16 // RUN: echo "%t/print_context.o 0x0" | llvm-symbolizer -print-source-context-lines=5 | FileCheck %s
17 
18 // Inputs/print_context.o built with plain -g -c from this source file
19 // Specifying -Xclang -fdebug-compilation-dir -Xclang . to make the debug info
20 // location independent.
21 
22 // CHECK: inc
23 // CHECK: print_context.c:3
24 // CHECK: 1  : #include
25 // CHECK: 2  :
26 // CHECK: 3 >: int inc
27 // CHECK: 4  :   return
28 // CHECK: 5  : }
29