| Mike Aizatsky | 17dbc28 | 2016-01-09 00:14:35 +0000 | [diff] [blame] | 1 | // REQUIRES: x86_64-linux |
| 2 | // RUN: %host_cc -O0 -g %s -o %t 2>&1 | ||||
| 3 | // RUN: %t 2>&1 | llvm-symbolizer -print-source-context-lines=5 -obj=%t | FileCheck %s --check-prefix=CHECK | ||||
| 4 | |||||
| 5 | #include <stdio.h> | ||||
| 6 | |||||
| 7 | int inc(int a) { | ||||
| 8 | return a + 1; | ||||
| 9 | } | ||||
| 10 | |||||
| 11 | int main() { | ||||
| 12 | printf("%p\n", inc); | ||||
| 13 | return 0; | ||||
| 14 | } | ||||
| 15 | |||||
| 16 | // CHECK: inc | ||||
| 17 | // CHECK: print_context.c:7 | ||||
| 18 | // CHECK: 5 : #include | ||||
| 19 | // CHECK: 6 : | ||||
| 20 | // CHECK: 7 >: int inc | ||||
| 21 | // CHECK: 8 : return | ||||
| 22 | // CHECK: 9 : } | ||||