Skip to content

Commit d906b6b

Browse files
committed
Fix non-Darwin platform build issue
1 parent bb0761e commit d906b6b

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

Sources/OpenSwiftUI/View/Modifier/AppearanceActionModifier.swift

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
// OpenSwiftUI
44
//
55
// Audited for RELEASE_2021
6-
// Status: WIP
6+
// Status: Blocked by _makeViewList
77
// ID: 8817D3B1C81ADA2B53E3500D727F785A
88

99
// MARK: - AppearanceActionModifier
@@ -79,6 +79,7 @@ extension AppearanceEffect: StatefulRule {
7979
typealias Value = Void
8080

8181
mutating func updateValue() {
82+
#if canImport(Darwin)
8283
if node.attribute == nil {
8384
node.attribute = .current
8485
}
@@ -89,9 +90,14 @@ extension AppearanceEffect: StatefulRule {
8990
}
9091
lastValue = modifier
9192
appeared()
93+
#else
94+
fatalError("See #39")
95+
#endif
9296
}
9397
}
9498

99+
#if canImport(Darwin) // See #39
100+
95101
// MARK: AppearanceEffect + RemovableAttribute
96102

97103
extension AppearanceEffect: RemovableAttribute {
@@ -114,6 +120,7 @@ extension AppearanceEffect: RemovableAttribute {
114120
nodeAttribute.graph.graphHost().graphInvalidation(from: nil)
115121
}
116122
}
123+
#endif
117124

118125
// MARK: - View Extension
119126

0 commit comments

Comments
 (0)