• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Test without serialization:
2 // RUN: %clang_cc1 -ast-dump %s | FileCheck %s
3 //
4 // Test with serialization:
5 // RUN: %clang_cc1 -emit-pch -o %t %s
6 // RUN: %clang_cc1 -x c -include-pch %t -ast-dump-all /dev/null \
7 // RUN: | sed -e "s/ <undeserialized declarations>//" -e "s/ imported//" \
8 // RUN: | FileCheck %s
9 
10 void foo1(void*);
11 void foo2(void* const);
12 
13 
bar()14 void bar() {
15   // CHECK:  FunctionDecl {{.*}} <line:{{.*}}, line:{{.*}}> line:{{.*}} bar 'void ()'
16 
17   foo1(0);
18   // CHECK: ImplicitCastExpr {{.*}} <col:{{.*}}> 'void *' <NullToPointer>
19 
20   foo2(0);
21   // CHECK: ImplicitCastExpr {{.*}} <col:{{.*}}> 'void *' <NullToPointer>
22 }
23