Skip to content

Commit 8fb7db4

Browse files
authored
Add isiOSAppOnVision to _NSSwiftProcessInfo (#1505)
1 parent 58ee897 commit 8fb7db4

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Sources/FoundationEssentials/ProcessInfo/ProcessInfo+ObjC.swift

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,14 @@ extension _NSSwiftProcessInfo {
6060
return dyld_get_active_platform() == PLATFORM_IOS
6161
#else
6262
return false
63+
#endif
64+
}
65+
66+
override var isiOSAppOnVision: Bool {
67+
#if os(visionOS)
68+
return dyld_get_active_platform() == PLATFORM_IOS || dyld_get_active_platform() == PLATFORM_IOSSIMULATOR
69+
#else
70+
return false
6371
#endif
6472
}
6573
}

0 commit comments

Comments
 (0)