Skip to content

Commit f509a00

Browse files
committed
Make file/line parameters explicit (#729)
1 parent a212fd9 commit f509a00

File tree

2 files changed

+10
-11
lines changed

2 files changed

+10
-11
lines changed

Sources/ComposableArchitecture/Internal/Deprecations.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ extension Reducer {
4848
action toLocalAction: CasePath<GlobalAction, (Int, Action)>,
4949
environment toLocalEnvironment: @escaping (GlobalEnvironment) -> Environment,
5050
breakpointOnNil: Bool = true,
51-
_ file: StaticString = #fileID,
52-
_ line: UInt = #line
51+
file: StaticString = #fileID,
52+
line: UInt = #line
5353
) -> Reducer<GlobalState, GlobalAction, GlobalEnvironment> {
5454
.init { globalState, globalAction, globalEnvironment in
5555
guard let (index, localAction) = toLocalAction.extract(from: globalAction) else {

Sources/ComposableArchitecture/Reducer.swift

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -463,8 +463,8 @@ public struct Reducer<State, Action, Environment> {
463463
action toLocalAction: CasePath<GlobalAction, Action>,
464464
environment toLocalEnvironment: @escaping (GlobalEnvironment) -> Environment,
465465
breakpointOnNil: Bool = true,
466-
_ file: StaticString = #fileID,
467-
_ line: UInt = #line
466+
file: StaticString = #fileID,
467+
line: UInt = #line
468468
) -> Reducer<GlobalState, GlobalAction, GlobalEnvironment> {
469469
.init { globalState, globalAction, globalEnvironment in
470470
guard let localAction = toLocalAction.extract(from: globalAction) else { return .none }
@@ -672,8 +672,8 @@ public struct Reducer<State, Action, Environment> {
672672
/// - Returns: A reducer that works on optional state.
673673
public func optional(
674674
breakpointOnNil: Bool = true,
675-
_ file: StaticString = #fileID,
676-
_ line: UInt = #line
675+
file: StaticString = #fileID,
676+
line: UInt = #line
677677
) -> Reducer<
678678
State?, Action, Environment
679679
> {
@@ -758,9 +758,8 @@ public struct Reducer<State, Action, Environment> {
758758
action toLocalAction: CasePath<GlobalAction, (ID, Action)>,
759759
environment toLocalEnvironment: @escaping (GlobalEnvironment) -> Environment,
760760
breakpointOnNil: Bool = true,
761-
_ file: StaticString = #fileID,
762-
_ line: UInt = #line
763-
761+
file: StaticString = #fileID,
762+
line: UInt = #line
764763
) -> Reducer<GlobalState, GlobalAction, GlobalEnvironment> {
765764
.init { globalState, globalAction, globalEnvironment in
766765
guard let (id, localAction) = toLocalAction.extract(from: globalAction) else { return .none }
@@ -830,8 +829,8 @@ public struct Reducer<State, Action, Environment> {
830829
action toLocalAction: CasePath<GlobalAction, (Key, Action)>,
831830
environment toLocalEnvironment: @escaping (GlobalEnvironment) -> Environment,
832831
breakpointOnNil: Bool = true,
833-
_ file: StaticString = #fileID,
834-
_ line: UInt = #line
832+
file: StaticString = #fileID,
833+
line: UInt = #line
835834
) -> Reducer<GlobalState, GlobalAction, GlobalEnvironment> {
836835
.init { globalState, globalAction, globalEnvironment in
837836
guard let (key, localAction) = toLocalAction.extract(from: globalAction) else { return .none }

0 commit comments

Comments
 (0)