mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
builtin, compiler: replace isnil(x) calls with x == unsafe { nil }
(a little faster without -prod) (#15759)
This commit is contained in:
@ -38,7 +38,7 @@ fn C.CFRelease(url &u8)
|
||||
pub fn resource_path() string {
|
||||
main_bundle := C.CFBundleGetMainBundle()
|
||||
resource_dir_url := C.CFBundleCopyResourcesDirectoryURL(main_bundle)
|
||||
if isnil(resource_dir_url) {
|
||||
if resource_dir_url == unsafe { nil } {
|
||||
panic('CFBundleCopyResourcesDirectoryURL failed')
|
||||
}
|
||||
buffer_size := 4096
|
||||
|
Reference in New Issue
Block a user