22// GraphShims.swift
33// OpenAttributeGraphShims
44
5+ public enum AttributeGraphVendor : String {
6+ case oag = " org.OpenSwiftUIProject.OpenAttributeGraph "
7+ case ag = " com.apple.AttributeGraph "
8+ case compute = " dev.incrematic.compute "
9+ }
10+
511#if OPENATTRIBUTEGRAPH_COMPUTE
612
713@_exported public import Compute
@@ -55,8 +61,12 @@ extension CachedValueOptions {
5561 public static var _1 : CachedValueOptions = . unprefetched
5662}
5763
64+ @available ( * , deprecated, renamed: " attributeGraphVendor " )
5865public let attributeGraphEnabled = true
66+ public let attributeGraphVendor = AttributeGraphVendor . compute
67+
5968#elseif OPENATTRIBUTEGRAPH_ATTRIBUTEGRAPH
69+
6070@_exported public import AttributeGraph
6171#if os(iOS) && !targetEnvironment(simulator)
6272@_exported public import _AttributeGraphDeviceSwiftShims
@@ -67,11 +77,17 @@ public typealias OAGChangedValueFlags = AGChangedValueFlags
6777public typealias OAGInputOptions = AGInputOptions
6878public typealias OAGValue = AGValue
6979public typealias OAGValueOptions = AGValueOptions
80+
81+ @available ( * , deprecated, renamed: " attributeGraphVendor " )
7082public let attributeGraphEnabled = true
83+ public let attributeGraphVendor = AttributeGraphVendor . ag
84+
7185#else
72- @_exported import OpenAttributeGraph
7386
87+ @_exported import OpenAttributeGraph
88+ @available ( * , deprecated, renamed: " attributeGraphVendor " )
7489public let attributeGraphEnabled = false
90+ public let attributeGraphVendor = AttributeGraphVendor . oag
7591#endif
7692
7793@available ( * , deprecated, message: " swiftToolchainSupported is always true " )
0 commit comments