Function swift_runtime_sys::root::swift_getRootPath
source ยท pub unsafe extern "C" fn swift_getRootPath() -> *const c_char
Expand description
Return the path of the Swift root.
If the path to libswiftCore is /usr/local/swift/lib/libswiftCore.dylib
,
this function would return /usr/local/swift
.
The path returned here can be overridden by setting the environment variable SWIFT_ROOT.
\return A string containing the full path to the Swift root directory, based
either on the location of the Swift runtime, or on the SWIFT_ROOT
environment variable if set. The string is owned by the runtime
and should not be freed.