Skip to content

Commit

Permalink
Primary associated types for trait publisher protocols
Browse files Browse the repository at this point in the history
  • Loading branch information
groue committed Sep 12, 2023
1 parent 0f09f0f commit cf4725d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Sources/CombineTraits/ImmediatePublisher.swift
Expand Up @@ -81,7 +81,7 @@ import Foundation
///
/// // Fails with the given error.
/// AnyImmediatePublisher.fail(error)
public protocol ImmediatePublisher: Publisher { }
public protocol ImmediatePublisher<Output, Failure>: Publisher { }

extension ImmediatePublisher {
/// Wraps this immediate publisher with a type eraser.
Expand Down
2 changes: 1 addition & 1 deletion Sources/CombineTraits/MaybePublisher.swift
Expand Up @@ -105,7 +105,7 @@ import Foundation
///
/// // Never publishes any value, never completes.
/// AnyMaybePublisher.never()
public protocol MaybePublisher: Publisher { }
public protocol MaybePublisher<Output, Failure>: Publisher { }

extension MaybePublisher {
/// Wraps this maybe publisher with a type eraser.
Expand Down
2 changes: 1 addition & 1 deletion Sources/CombineTraits/SinglePublisher.swift
Expand Up @@ -103,7 +103,7 @@ import Foundation
///
/// // Never publishes any value, never completes.
/// AnySinglePublisher.never()
public protocol SinglePublisher: MaybePublisher { }
public protocol SinglePublisher<Output, Failure>: MaybePublisher { }

extension SinglePublisher {
/// Wraps this single publisher with a type eraser.
Expand Down

0 comments on commit cf4725d

Please sign in to comment.