1// RUN: rm -rf %t && mkdir -p %t
2// RUN: %clang -c -o %t/EmptyClassFoo.o %S/Inputs/EmptyClassFoo.m
3// RUN: ar r %t/libFooClass.a %t/EmptyClassFoo.o
4// RUN: %clang -c -o %t/force-objc.o %s
5// RUN: %llvm_jitlink -ObjC %t/force-objc.o -L%t -lFooClass
6//
7// REQUIRES: system-darwin && host-arch-compatible
8
9id objc_getClass(const char *name);
10
11int main(int argc, char *argv[]) {
12 // Return succeess if we find Foo, error otherwise.
13 return objc_getClass(name: "Foo") ? 0 : 1;
14}
15

source code of compiler-rt/test/orc/TestCases/Darwin/Generic/llvm-jitlink-force-link-objc.m