1 | // RUN: %clang_cl -MD -c -o %t %s |
---|---|
2 | // RUN: %llvm_jitlink %t |
3 | |
4 | extern "C"__declspec(dllimport) void llvm_jitlink_setTestResultOverride( |
5 | long Value); |
6 | |
7 | extern "C"int init() { return -1; } |
8 | extern "C"int init2() { return -2; } |
9 | |
10 | extern "C"int a = init(); |
11 | extern "C"int b = 2; |
12 | extern "C"int c = init2(); |
13 | |
14 | int main(int argc, char *argv[]) { |
15 | llvm_jitlink_setTestResultOverride(Value: a + b + c + 1); |
16 | return 0; |
17 | } |
18 |