Skip to content

Commit

Permalink
Fix non-darwin build crash issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Kyle-Ye committed Mar 3, 2024
1 parent a4c35a4 commit a189520
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/OpenSwiftUI/Core/Graph/GraphHost.swift
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class GraphHost {
// data.globalSubgraph.apply
isInstantiated = false
}
if let graph = data.graph {
if let _ = data.graph {
data.globalSubgraph.invalidate()
// graph.context = nil
// graph.invalidate()
Expand Down
3 changes: 3 additions & 0 deletions Sources/OpenSwiftUI/Core/Graph/GraphMutation.swift
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ struct EmptyGraphMutation: GraphMutation {
}
}

// FIXME: #39
#if canImport(Darwin)
struct InvalidatingGraphMutation: GraphMutation {
let attribute: OGWeakAttribute

Expand All @@ -33,6 +35,7 @@ struct InvalidatingGraphMutation: GraphMutation {
return mutation.attribute == attribute
}
}
#endif

struct CustomGraphMutation: GraphMutation {
let body: () -> Void
Expand Down

0 comments on commit a189520

Please sign in to comment.