diff --git a/RxSwift/Traits/PrimitiveSequence.swift b/RxSwift/Traits/PrimitiveSequence.swift index 290d9cf39..4db796366 100644 --- a/RxSwift/Traits/PrimitiveSequence.swift +++ b/RxSwift/Traits/PrimitiveSequence.swift @@ -627,20 +627,6 @@ extension PrimitiveSequenceType where TraitType == MaybeTrait { } } -extension PrimitiveSequence where Trait == CompletableTrait, Element == Never { - /** - Concatenates the second observable sequence to `self` upon successful termination of `self`. - - - seealso: [concat operator on reactivex.io](http://reactivex.io/documentation/operators/concat.html) - - - parameter second: Second observable sequence. - - returns: An observable sequence that contains the elements of `self`, followed by those of the second sequence. - */ - public func concat(_ second: PrimitiveSequence) -> PrimitiveSequence { - return Completable.concat(self, second) - } -} - extension PrimitiveSequenceType where TraitType == CompletableTrait, ElementType == Never { /** Returns an empty observable sequence, using the specified scheduler to send out the single `Completed` message. @@ -653,6 +639,18 @@ extension PrimitiveSequenceType where TraitType == CompletableTrait, ElementType return PrimitiveSequence(raw: Observable.empty()) } + /** + Concatenates the second observable sequence to `self` upon successful termination of `self`. + + - seealso: [concat operator on reactivex.io](http://reactivex.io/documentation/operators/concat.html) + + - parameter second: Second observable sequence. + - returns: An observable sequence that contains the elements of `self`, followed by those of the second sequence. + */ + public func concat(_ second: PrimitiveSequence) -> PrimitiveSequence { + return Completable.concat(primitiveSequence, second) + } + /** Concatenates all observable sequences in the given sequence, as long as the previous observable sequence terminated successfully.