Update LOCAL_PATCHES after libsanitizer merge.
[official-gcc.git] / libphobos / testsuite / libphobos.shared / libloaddep.d
blob93a2dabc4cae3b8a205d99c285b99b5c1d9424b0
1 import core.runtime, core.sys.posix.dlfcn;
3 extern(C) alias RunTests = int function();
5 extern(C) int runDepTests(const char* name)
7 auto h = rt_loadLibrary(name);
8 if (h is null) return false;
9 auto runTests = cast(RunTests).dlsym(h, "runTests");
10 assert(runTests !is null);
11 if (!runTests()) return false;
12 return rt_unloadLibrary(h);