Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pitch: Deprecate ActionProtocol #248

Merged
merged 2 commits into from Feb 27, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions Sources/Action.swift
Expand Up @@ -207,6 +207,7 @@ private struct ActionState {
}

/// A protocol used to constraint `Action` initializers.
@available(swift, deprecated: 3.1, message: "This protocol is no longer necessary and will be removed in a future version of ReactiveSwift. Use Action directly instead.")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since it cannot be suppressed anyway, we may deprecate it for 3.0.x too.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not so sure: currently it only generates a warning inside ReactiveSwift, so I like the idea that it won't generate any warnings for consumers.

Copy link
Member

@andersio andersio Feb 15, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This would happen when building through Carthage in Swift 3.1 anyway... https://travis-ci.org/ReactiveCocoa/ReactiveSwift/jobs/201869272#L821

public protocol ActionProtocol: BindingTargetProtocol {
/// The type of argument to apply the action to.
associatedtype Input
Expand Down
2 changes: 1 addition & 1 deletion Sources/Atomic.swift
Expand Up @@ -33,7 +33,7 @@ internal protocol AtomicStateProtocol {
internal struct UnsafeAtomicState<State: RawRepresentable>: AtomicStateProtocol where State.RawValue == Int32 {
internal typealias Transition = (expected: State, next: State)
#if os(macOS) || os(iOS) || os(tvOS) || os(watchOS)
private let value: UnsafeMutablePointer<Int32>
internal let value: UnsafeMutablePointer<Int32>

/// Create a finite state machine with the specified initial state.
///
Expand Down