Skip to content

Commit 60dc806

Browse files
stephencelisactions-user
authored andcommitted
Run swift-format
1 parent af88fe4 commit 60dc806

File tree

1 file changed

+32
-8
lines changed

1 file changed

+32
-8
lines changed

Sources/ComposableArchitecture/Internal/Deprecations.swift

Lines changed: 32 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,13 @@ import SwiftUI
3030
}
3131

3232
extension Reducer {
33-
@available(*, deprecated, message: "'Reducer.binding()' no longer takes an explicit extract function and instead relies on 'BindableAction'")
34-
public func binding(action toBindingAction: @escaping (Action) -> BindingAction<State>?) -> Self {
33+
@available(
34+
*, deprecated,
35+
message:
36+
"'Reducer.binding()' no longer takes an explicit extract function and instead relies on 'BindableAction'"
37+
)
38+
public func binding(action toBindingAction: @escaping (Action) -> BindingAction<State>?) -> Self
39+
{
3540
Self { state, action, environment in
3641
toBindingAction(action)?.set(&state)
3742
return self.run(&state, action, environment)
@@ -40,7 +45,9 @@ import SwiftUI
4045
}
4146

4247
extension ViewStore {
43-
@available(*, deprecated, message: "Bindings are now derived using 'BindableState' and 'BindableAction'")
48+
@available(
49+
*, deprecated, message: "Bindings are now derived using 'BindableState' and 'BindableAction'"
50+
)
4451
public func binding<LocalState>(
4552
keyPath: WritableKeyPath<State, LocalState>,
4653
send action: @escaping (BindingAction<State>) -> Action
@@ -54,7 +61,11 @@ import SwiftUI
5461
}
5562
#else
5663
extension BindingAction {
57-
@available(*, deprecated, message: "Values are now wrapped in 'BindableState'. Upgrade to Xcode 12.5 or greater for access to 'BindableState'.")
64+
@available(
65+
*, deprecated,
66+
message:
67+
"Values are now wrapped in 'BindableState'. Upgrade to Xcode 12.5 or greater for access to 'BindableState'."
68+
)
5869
public static func set<Value>(
5970
_ keyPath: WritableKeyPath<Root, Value>,
6071
_ value: Value
@@ -68,7 +79,11 @@ import SwiftUI
6879
)
6980
}
7081

71-
@available(*, deprecated, message: "Values are now wrapped in 'BindableState'. Upgrade to Xcode 12.5 or greater for access to 'BindableState'.")
82+
@available(
83+
*, deprecated,
84+
message:
85+
"Values are now wrapped in 'BindableState'. Upgrade to Xcode 12.5 or greater for access to 'BindableState'."
86+
)
7287
public static func ~= <Value>(
7388
keyPath: WritableKeyPath<Root, Value>,
7489
bindingAction: Self
@@ -78,8 +93,13 @@ import SwiftUI
7893
}
7994

8095
extension Reducer {
81-
@available(*, deprecated, message: "'Reducer.binding()' no longer takes an explicit extract function and instead relies on 'BindableAction'. Upgrade to Xcode 12.5 or greater for access to 'Reducer.binding()' and 'BindableAction'.")
82-
public func binding(action toBindingAction: @escaping (Action) -> BindingAction<State>?) -> Self {
96+
@available(
97+
*, deprecated,
98+
message:
99+
"'Reducer.binding()' no longer takes an explicit extract function and instead relies on 'BindableAction'. Upgrade to Xcode 12.5 or greater for access to 'Reducer.binding()' and 'BindableAction'."
100+
)
101+
public func binding(action toBindingAction: @escaping (Action) -> BindingAction<State>?) -> Self
102+
{
83103
Self { state, action, environment in
84104
toBindingAction(action)?.set(&state)
85105
return self.run(&state, action, environment)
@@ -88,7 +108,11 @@ import SwiftUI
88108
}
89109

90110
extension ViewStore {
91-
@available(*, deprecated, message: "Bindings are now derived using 'BindableState' and 'BindableAction'. Upgrade to Xcode 12.5 or greater for access to 'BindableState' and 'BindableAction'.")
111+
@available(
112+
*, deprecated,
113+
message:
114+
"Bindings are now derived using 'BindableState' and 'BindableAction'. Upgrade to Xcode 12.5 or greater for access to 'BindableState' and 'BindableAction'."
115+
)
92116
public func binding<LocalState>(
93117
keyPath: WritableKeyPath<State, LocalState>,
94118
send action: @escaping (BindingAction<State>) -> Action

0 commit comments

Comments
 (0)