Debian Codegraph @

clang/test/Interpreter/execute-pch.cpp

raw
1 // REQUIRES: host-supports-jit
2 // UNSUPPORTED: system-aix
3 //
4 // RUN: rm -rf %t
5 // RUN: mkdir -p %t
6 // RUN: split-file %s %t
7 //
8 // RUN: %clang -fmax-type-align=16 -Xclang -fdeprecated-macro -fno-stack-protector -Xclang -fwrapv -Xclang -fblocks -Xclang -fskip-odr-check-in-gmf -fexceptions -fcxx-exceptions -fgnuc-version=0 -target %host-jit-triple -Xclang -fblocks -Xclang -fmax-type-align=8 -Xclang -fincremental-extensions -Xclang -emit-pch -x c++-header -o %t/include.pch %t/include.hpp
9 //
10 // RUN: cat %t/main.cpp \
11 // RUN: | clang-repl -Xcc -fgnuc-version=0 -Xcc -fno-stack-protector -Xcc -fwrapv -Xcc -fblocks -Xcc -fskip-odr-check-in-gmf -Xcc -fmax-type-align=8 -Xcc -include-pch -Xcc %t/include.pch \
12 // RUN: | FileCheck %s
13
14 //--- include.hpp
15
16 int f_pch() { return 5; }
17
18 //--- main.cpp
19
20 extern "C" int printf(const char *, ...);
21 printf("f_pch = %d\n", f_pch());
22
23 // CHECK: f_pch = 5