diff --git a/Sources/BasicContainers/RigidArray/RigidArray+Append.swift b/Sources/BasicContainers/RigidArray/RigidArray+Append.swift index ca77fa15..0099c261 100644 --- a/Sources/BasicContainers/RigidArray/RigidArray+Append.swift +++ b/Sources/BasicContainers/RigidArray/RigidArray+Append.swift @@ -349,10 +349,11 @@ extension RigidArray { #if compiler(>=6.4) && UnstableContainersPreview @inlinable internal mutating func _append< - Source: Iterable_ & ~Copyable & ~Escapable, E + Source: Iterable_ & ~Copyable & ~Escapable >( copying newElements: borrowing Source - ) throws(E) { + ) throws(Source.Failure_) + where Source.Element_ == Element { let target = _freeSpace _count += try newElements._copyContents(intoPrefixOf: target) } @@ -371,10 +372,11 @@ extension RigidArray { @_alwaysEmitIntoClient @inline(__always) public mutating func append< - Source: Iterable_ & ~Copyable & ~Escapable, E + Source: Iterable_ & ~Copyable & ~Escapable >( copying newElements: borrowing Source - ) throws(E) { + ) throws(Source.Failure_) + where Source.Element_ == Element { try _append(copying: newElements) } #endif @@ -413,9 +415,12 @@ extension RigidArray { @_alwaysEmitIntoClient @inline(__always) public mutating func append< - Source: Iterable_ & Sequence - >(copying newElements: Source) { - _append(copying: newElements) + Source: Iterable_ & Sequence + >( + copying newElements: Source + ) throws(Source.Failure_) + where Source.Element_ == Element { + try _append(copying: newElements) } #endif } diff --git a/Sources/BasicContainers/RigidArray/RigidArray+Initializers.swift b/Sources/BasicContainers/RigidArray/RigidArray+Initializers.swift index 0011174b..62976415 100644 --- a/Sources/BasicContainers/RigidArray/RigidArray+Initializers.swift +++ b/Sources/BasicContainers/RigidArray/RigidArray+Initializers.swift @@ -124,10 +124,11 @@ extension RigidArray /*where Element: Copyable*/ { /// The container must not contain more than `capacity` elements. @_alwaysEmitIntoClient @inline(__always) - public init & ~Copyable & ~Escapable, E>( + public init( capacity: Int, copying contents: borrowing Source - ) throws(E) { + ) throws(Source.Failure_) + where Source.Element_ == Element { self.init(capacity: capacity) try self.append(copying: contents) } @@ -145,12 +146,13 @@ extension RigidArray /*where Element: Copyable*/ { /// The container must not contain more than `capacity` elements. @_alwaysEmitIntoClient @inline(__always) - public init & Sequence>( + public init>( capacity: Int, copying contents: Source - ) { + ) throws(Source.Failure_) + where Source.Element_ == Element { self.init(capacity: capacity) - self.append(copying: contents) + try self.append(copying: contents) } #endif diff --git a/Sources/BasicContainers/RigidSet/RigidSet+Initializers.swift b/Sources/BasicContainers/RigidSet/RigidSet+Initializers.swift index 44b79943..7146c0b3 100644 --- a/Sources/BasicContainers/RigidSet/RigidSet+Initializers.swift +++ b/Sources/BasicContainers/RigidSet/RigidSet+Initializers.swift @@ -120,25 +120,27 @@ extension RigidSet /* where Element: Copyable */ { @_alwaysEmitIntoClient @inline(__always) public init< - S: Iterable_ & Sequence + S: Iterable_ & Sequence >( capacity: Int, copying contents: borrowing S - ) { + ) throws(S.Failure_) + where S.Element_ == Element { self.init(capacity: capacity) - self._insert(copying: contents) + try self._insert(copying: contents) } @_alwaysEmitIntoClient @inline(__always) public init< - S: Iterable_ & Collection + S: Iterable_ & Collection >( capacity: Int? = nil, copying contents: S - ) { + ) throws(S.Failure_) + where S.Element_ == Element { self.init(capacity: capacity ?? contents.count) - self._insert(copying: contents) + try self._insert(copying: contents) } #endif } diff --git a/Sources/BasicContainers/RigidSet/RigidSet+Insertions.swift b/Sources/BasicContainers/RigidSet/RigidSet+Insertions.swift index 19e74909..0fdd0c99 100644 --- a/Sources/BasicContainers/RigidSet/RigidSet+Insertions.swift +++ b/Sources/BasicContainers/RigidSet/RigidSet+Insertions.swift @@ -223,11 +223,11 @@ extension RigidSet /* where Element: Copyable */ { #if UnstableContainersPreview @_alwaysEmitIntoClient package mutating func _insert< - Failure: Error, - S: Iterable_ & ~Copyable & ~Escapable + S: Iterable_ & ~Copyable & ~Escapable >( copying items: borrowing S - ) throws(S.Failure_) { + ) throws(S.Failure_) + where S.Element_ == Element { var it = items.makeIterableIterator_() while true { let span = try it.nextSpan_() @@ -263,11 +263,12 @@ extension RigidSet /* where Element: Copyable */ { @_alwaysEmitIntoClient @inline(__always) public mutating func insert< - S: Iterable_ & Sequence + S: Iterable_ & Sequence >( copying items: borrowing S - ) { - _insert(copying: items) + ) throws(S.Failure_) + where S.Element_ == Element { + try _insert(copying: items) } #endif } diff --git a/Sources/BasicContainers/UniqueArray/UniqueArray+Append.swift b/Sources/BasicContainers/UniqueArray/UniqueArray+Append.swift index 16795e81..7a66eddb 100644 --- a/Sources/BasicContainers/UniqueArray/UniqueArray+Append.swift +++ b/Sources/BasicContainers/UniqueArray/UniqueArray+Append.swift @@ -310,10 +310,11 @@ extension UniqueArray { #if compiler(>=6.4) && UnstableContainersPreview @inlinable internal mutating func _append< - Source: Iterable_ & ~Copyable & ~Escapable, E + Source: Iterable_ & ~Copyable & ~Escapable >( copying newElements: borrowing Source - ) throws(E) { + ) throws(Source.Failure_) + where Source.Element_ == Element { _ensureFreeCapacity(newElements.underestimatedCount_) var it = newElements.makeIterableIterator_() while true { @@ -343,10 +344,11 @@ extension UniqueArray { @_alwaysEmitIntoClient @inline(__always) public mutating func append< - Source: Iterable_ & ~Copyable & ~Escapable, E + Source: Iterable_ & ~Copyable & ~Escapable >( copying newElements: borrowing Source - ) throws(E) { + ) throws(Source.Failure_) + where Source.Element_ == Element { try self._append(copying: newElements) } @@ -397,9 +399,12 @@ extension UniqueArray { @_alwaysEmitIntoClient @inline(__always) public mutating func append< - Source: Iterable_ & Sequence - >(copying newElements: Source) { - self._append(copying: newElements) + Source: Iterable_ & Sequence + >( + copying newElements: Source + ) throws(Source.Failure_) + where Source.Element_ == Element { + try self._append(copying: newElements) } #endif } diff --git a/Sources/BasicContainers/UniqueArray/UniqueArray+Initializers.swift b/Sources/BasicContainers/UniqueArray/UniqueArray+Initializers.swift index 20ad1c9f..678933f1 100644 --- a/Sources/BasicContainers/UniqueArray/UniqueArray+Initializers.swift +++ b/Sources/BasicContainers/UniqueArray/UniqueArray+Initializers.swift @@ -96,10 +96,11 @@ extension UniqueArray /*where Element: Copyable*/ { /// The sequence must not contain more than `capacity` elements. @_alwaysEmitIntoClient @inline(__always) - public init & ~Copyable & ~Escapable, E>( + public init( capacity: Int? = nil, copying contents: borrowing Source - ) throws(E) { + ) throws(Source.Failure_) + where Source.Element_ == Element { self.init(minimumCapacity: capacity ?? 0) try self.append(copying: contents) } @@ -132,12 +133,13 @@ extension UniqueArray /*where Element: Copyable*/ { /// - contents: The container whose contents to copy into the new array. @_alwaysEmitIntoClient @inline(__always) - public init & Sequence>( + public init>( capacity: Int? = nil, copying contents: Source - ) { + ) throws(Source.Failure_) + where Source.Element_ == Element { self.init(minimumCapacity: capacity ?? 0) - self.append(copying: contents) + try self.append(copying: contents) } #endif diff --git a/Sources/BasicContainers/UniqueSet/UniqueSet+Initializers.swift b/Sources/BasicContainers/UniqueSet/UniqueSet+Initializers.swift index 98c9b46b..03ffcf4f 100644 --- a/Sources/BasicContainers/UniqueSet/UniqueSet+Initializers.swift +++ b/Sources/BasicContainers/UniqueSet/UniqueSet+Initializers.swift @@ -96,12 +96,13 @@ extension UniqueSet where Element: Copyable { #if UnstableContainersPreview @_alwaysEmitIntoClient public init< - S: Iterable_ & Sequence + S: Iterable_ & Sequence >( copying items: borrowing S - ) { + ) throws(S.Failure_) + where S.Element_ == Element { self.init() - self._insert(copying: items) + try self._insert(copying: items) } #endif } diff --git a/Sources/BasicContainers/UniqueSet/UniqueSet+Insertions.swift b/Sources/BasicContainers/UniqueSet/UniqueSet+Insertions.swift index ad7857f7..1a9d235b 100644 --- a/Sources/BasicContainers/UniqueSet/UniqueSet+Insertions.swift +++ b/Sources/BasicContainers/UniqueSet/UniqueSet+Insertions.swift @@ -173,11 +173,12 @@ extension UniqueSet /* where Element: Copyable */ { @_alwaysEmitIntoClient @inline(__always) public mutating func insert< - S: Iterable_ & Sequence + S: Iterable_ & Sequence >( copying items: borrowing S - ) { - _insert(copying: items) + ) throws(S.Failure_) + where S.Element_ == Element { + try _insert(copying: items) } #endif } diff --git a/Sources/ContainersPreview/Protocols/Container/RangeReplaceableContainer.swift b/Sources/ContainersPreview/Protocols/Container/RangeReplaceableContainer.swift index b6908449..10ba9f42 100644 --- a/Sources/ContainersPreview/Protocols/Container/RangeReplaceableContainer.swift +++ b/Sources/ContainersPreview/Protocols/Container/RangeReplaceableContainer.swift @@ -427,11 +427,11 @@ where @inlinable public mutating func append< - Failure: Error, - S: Iterable_ & ~Copyable & ~Escapable + S: Iterable_ & ~Copyable & ~Escapable >( copying items: borrowing S - ) throws(Failure) { + ) throws(S.Failure_) + where S.Element_ == Element { var it = items.makeIterableIterator_() while true { let span = try it.nextSpan_() diff --git a/Sources/ContainersPreview/Protocols/IterableIteratorProtocol+Copy.swift b/Sources/ContainersPreview/Protocols/IterableIteratorProtocol+Copy.swift index fc95808f..73007d3a 100644 --- a/Sources/ContainersPreview/Protocols/IterableIteratorProtocol+Copy.swift +++ b/Sources/ContainersPreview/Protocols/IterableIteratorProtocol+Copy.swift @@ -25,9 +25,9 @@ where /// will get copied. @inlinable @_lifetime(copy self) - public consuming func copy() -> BorrowingMapProducer { + public consuming func copy() -> BorrowingMapProducer { // FIXME: We could also just define a direct implementation that avoids the closure. - BorrowingMapProducer(_base: self, transform: { $0 }) + self.map { $0 } } // Note: We could also define `collect(into:)` directly on borrowing iterators, diff --git a/Sources/DequeModule/RigidDeque/RigidDeque+Append.swift b/Sources/DequeModule/RigidDeque/RigidDeque+Append.swift index 44519882..942cd4ed 100644 --- a/Sources/DequeModule/RigidDeque/RigidDeque+Append.swift +++ b/Sources/DequeModule/RigidDeque/RigidDeque+Append.swift @@ -313,8 +313,9 @@ extension RigidDeque /*where Element: Copyable*/ { #if compiler(>=6.4) && UnstableContainersPreview @_alwaysEmitIntoClient internal mutating func _append< - S: Iterable_ & ~Copyable & ~Escapable, E - >(copying items: borrowing S) throws(E) { + S: Iterable_ & ~Copyable & ~Escapable + >(copying items: borrowing S) throws(S.Failure_) + where S.Element_ == Element { var it = items.makeIterableIterator_() while true { let span = try it.nextSpan_() @@ -334,9 +335,10 @@ extension RigidDeque /*where Element: Copyable*/ { /// /// - Complexity: O(*m*), where *m* is the length of `newElements`. @_alwaysEmitIntoClient - public mutating func append & ~Copyable & ~Escapable, E>( + public mutating func append( copying newElements: borrowing S - ) throws(E) { + ) throws(S.Failure_) + where S.Element_ == Element { try self._append(copying: newElements) } #endif @@ -375,10 +377,11 @@ extension RigidDeque /*where Element: Copyable*/ { /// - Complexity: O(*m*), where *m* is the length of `items`. @available(SwiftStdlib 5.0, *) @_alwaysEmitIntoClient public mutating func append< - S: Iterable_ & Sequence - >( + S: Iterable_ & Sequence + >( copying items: S - ) { + ) throws(S.Failure_) + where S.Element_ == Element { try self._append(copying: items) } #endif diff --git a/Sources/DequeModule/RigidDeque/RigidDeque+Initializers.swift b/Sources/DequeModule/RigidDeque/RigidDeque+Initializers.swift index 3b9c2de7..fb1a09f8 100644 --- a/Sources/DequeModule/RigidDeque/RigidDeque+Initializers.swift +++ b/Sources/DequeModule/RigidDeque/RigidDeque+Initializers.swift @@ -131,12 +131,11 @@ extension RigidDeque /*where Element: Copyable*/ { /// The sequence must not contain more than `capacity` elements. @_alwaysEmitIntoClient @inline(__always) - public init< - S: Iterable_ & ~Copyable & ~Escapable, E - >( + public init( capacity: Int, copying contents: borrowing S - ) throws(E) { + ) throws(S.Failure_) + where S.Element_ == Element { self.init(capacity: capacity) try self._append(copying: contents) } @@ -186,14 +185,13 @@ extension RigidDeque /*where Element: Copyable*/ { /// The sequence must not contain more than `capacity` elements. @_alwaysEmitIntoClient @inline(__always) - public init< - S: Iterable_ & Sequence - >( + public init>( capacity: Int, copying contents: borrowing S - ) { + ) throws(S.Failure_) + where S.Element_ == Element { self.init(capacity: capacity) - self._append(copying: contents) + try self._append(copying: contents) } /// Creates a new deque with the specified capacity, holding a copy @@ -207,14 +205,13 @@ extension RigidDeque /*where Element: Copyable*/ { /// The sequence must not contain more than `capacity` elements. @_alwaysEmitIntoClient @inline(__always) - public init< - S: Iterable_ & Collection - >( + public init>( capacity: Int? = nil, copying contents: S - ) { + ) throws(S.Failure_) + where S.Element_ == Element { self.init(capacity: capacity ?? contents.count) - self._append(copying: contents) + try self._append(copying: contents) } #endif diff --git a/Sources/DequeModule/RigidDeque/RigidDeque+Prepend.swift b/Sources/DequeModule/RigidDeque/RigidDeque+Prepend.swift index 85b53577..bd67fa8e 100644 --- a/Sources/DequeModule/RigidDeque/RigidDeque+Prepend.swift +++ b/Sources/DequeModule/RigidDeque/RigidDeque+Prepend.swift @@ -290,8 +290,11 @@ extension RigidDeque /*where Element: Copyable*/ { #if compiler(>=6.4) && UnstableContainersPreview @inlinable internal mutating func _prepend< - S: Iterable_ & ~Copyable & ~Escapable, E - >(copying items: borrowing S) throws(E) { + S: Iterable_ & ~Copyable & ~Escapable + >( + copying items: borrowing S + ) throws(S.Failure_) + where S.Element_ == Element { // We don't know the exact count of new elements, so we cannot initialize // them in place. Append them to the end of the deque first, then rotate // them to their correct location. @@ -306,13 +309,14 @@ extension RigidDeque /*where Element: Copyable*/ { @inlinable internal mutating func _prepend< - S: Iterable_ & ~Copyable & ~Escapable, E + S: Iterable_ & ~Copyable & ~Escapable >( copying items: borrowing S, exactCount: Int - ) throws(E) { + ) throws(S.Failure_) + where S.Element_ == Element { var it = items.makeIterableIterator_() - try self.prepend(addingCount: exactCount) { (target) throws(E) in + try self.prepend(addingCount: exactCount) { (target) throws(S.Failure_) in let span = try it.nextSpan_(maximumCount: target.freeCapacity) target._append(copying: span) } @@ -333,9 +337,10 @@ extension RigidDeque /*where Element: Copyable*/ { /// /// - Complexity: O(*m*), where *m* is the length of `items`. @_alwaysEmitIntoClient - public mutating func prepend & ~Copyable & ~Escapable, E>( + public mutating func prepend( copying items: borrowing S - ) throws(E) { + ) throws(S.Failure_) + where S.Element_ == Element { try self._prepend(copying: items) } @@ -437,10 +442,11 @@ extension RigidDeque /*where Element: Copyable*/ { /// /// - Complexity: O(*m*), where *m* is the length of `items`. @_alwaysEmitIntoClient - public mutating func prepend & Sequence>( + public mutating func prepend>( copying items: borrowing S - ) { - self._prepend(copying: items) + ) throws(S.Failure_) + where S.Element_ == Element { + try self._prepend(copying: items) } /// Copies the elements of a borrowing sequence to the front of this deque. @@ -453,10 +459,11 @@ extension RigidDeque /*where Element: Copyable*/ { /// /// - Complexity: O(*m*), where *m* is the length of `items`. @_alwaysEmitIntoClient - public mutating func prepend & Collection>( + public mutating func prepend>( copying items: borrowing S - ) { - self._prepend(copying: items, exactCount: items.count) + ) throws(S.Failure_) + where S.Element_ == Element { + try self._prepend(copying: items, exactCount: items.count) } /// Copies the elements of a container to the front of this deque. diff --git a/Sources/DequeModule/UniqueDeque/UniqueDeque+Append.swift b/Sources/DequeModule/UniqueDeque/UniqueDeque+Append.swift index 37f0b5d5..e5a58033 100644 --- a/Sources/DequeModule/UniqueDeque/UniqueDeque+Append.swift +++ b/Sources/DequeModule/UniqueDeque/UniqueDeque+Append.swift @@ -299,9 +299,10 @@ extension UniqueDeque /*where Element: Copyable*/ { #if compiler(>=6.4) && UnstableContainersPreview @_alwaysEmitIntoClient - internal mutating func _append< - S: Iterable_ & ~Copyable & ~Escapable, E - >(copying items: borrowing S) throws(E) { + internal mutating func _append( + copying items: borrowing S + ) throws(S.Failure_) + where S.Element_ == Element { var it = items.makeIterableIterator_() while true { let span = try it.nextSpan_() @@ -323,9 +324,10 @@ extension UniqueDeque /*where Element: Copyable*/ { /// - Complexity: O(*m*), where *m* is the length of `items`, when amortized /// over many similar invocations on the same deque @_alwaysEmitIntoClient - public mutating func append & ~Copyable & ~Escapable, E>( + public mutating func append( copying items: borrowing S - ) throws(E) { + ) throws(S.Failure_) + where S.Element_ == Element { try self._append(copying: items) } #endif @@ -373,11 +375,10 @@ extension UniqueDeque /*where Element: Copyable*/ { /// - Complexity: O(*m*), where *m* is the length of `items`, when /// amortized over many similar invocations over the same deque. @_alwaysEmitIntoClient - public mutating func append< - S: Iterable_ & Sequence - >( + public mutating func append>( copying items: S - ) { + ) throws(S.Failure_) + where S.Element_ == Element { try self._append(copying: items) } #endif diff --git a/Sources/DequeModule/UniqueDeque/UniqueDeque+Initializers.swift b/Sources/DequeModule/UniqueDeque/UniqueDeque+Initializers.swift index 7f8fd9f6..ec6eb187 100644 --- a/Sources/DequeModule/UniqueDeque/UniqueDeque+Initializers.swift +++ b/Sources/DequeModule/UniqueDeque/UniqueDeque+Initializers.swift @@ -144,12 +144,11 @@ extension UniqueDeque /*where Element: Copyable*/ { /// - contents: A sequence whose contents to copy into the new deque. @_alwaysEmitIntoClient @inline(__always) - public init< - S: Iterable_ & ~Copyable & ~Escapable, E - >( + public init( capacity: Int? = nil, copying contents: borrowing S - ) throws(E) { + ) throws(S.Failure_) + where S.Element_ == Element { self.init(minimumCapacity: capacity ?? 0) try self._append(copying: contents) } @@ -183,14 +182,13 @@ extension UniqueDeque /*where Element: Copyable*/ { /// The sequence must not contain more than `capacity` elements. @_alwaysEmitIntoClient @inline(__always) - public init< - S: Iterable_ & Sequence - >( + public init>( capacity: Int? = nil, copying contents: S - ) { + ) throws(S.Failure_) + where S.Element_ == Element { self.init(minimumCapacity: capacity ?? contents.underestimatedCount) - self._append(copying: contents) + try self._append(copying: contents) } /// Creates a new deque with the specified capacity, holding a copy @@ -202,14 +200,13 @@ extension UniqueDeque /*where Element: Copyable*/ { /// The sequence must not contain more than `capacity` elements. @_alwaysEmitIntoClient @inline(__always) - public init< - S: Iterable_ & Collection - >( + public init>( capacity: Int? = nil, copying contents: S - ) { + ) throws(S.Failure_) + where S.Element_ == Element { self.init(minimumCapacity: capacity ?? contents.count) - self._append(copying: contents) + try self._append(copying: contents) } #endif diff --git a/Sources/DequeModule/UniqueDeque/UniqueDeque+Prepend.swift b/Sources/DequeModule/UniqueDeque/UniqueDeque+Prepend.swift index f4e2a3c6..53fb9bbc 100644 --- a/Sources/DequeModule/UniqueDeque/UniqueDeque+Prepend.swift +++ b/Sources/DequeModule/UniqueDeque/UniqueDeque+Prepend.swift @@ -321,9 +321,11 @@ extension UniqueDeque /*where Element: Copyable*/ { #if compiler(>=6.4) && UnstableContainersPreview @inlinable - internal mutating func _prepend< - S: Iterable_ & ~Copyable & ~Escapable, E - >(copying items: borrowing S) throws(E) { + internal mutating func _prepend( + copying items: borrowing S + ) throws(S.Failure_) + where S.Element_ == Element + { // We don't know the exact count of new elements, so we cannot initialize // them in place. Append them to the end of the deque first, then rotate // them to their correct location. @@ -337,14 +339,13 @@ extension UniqueDeque /*where Element: Copyable*/ { } @inlinable - internal mutating func _prepend< - S: Iterable_ & ~Copyable & ~Escapable, E - >( + internal mutating func _prepend( copying items: borrowing S, exactCount: Int - ) throws(E) { + ) throws(S.Failure_) + where S.Element_ == Element { var it = items.makeIterableIterator_() - try self.prepend(addingCount: exactCount) { (target) throws(E) in + try self.prepend(addingCount: exactCount) { (target) throws(S.Failure_) in let span = try it.nextSpan_(maximumCount: target.freeCapacity) target._append(copying: span) } @@ -366,11 +367,10 @@ extension UniqueDeque /*where Element: Copyable*/ { /// - Complexity: O(*m*), where *m* is the length of `items`, as amortized /// over many similar invocations on the same deque. @_alwaysEmitIntoClient - public mutating func prepend< - S: Iterable_ & ~Copyable & ~Escapable, E - >( + public mutating func prepend( copying items: borrowing S - ) throws(E) { + ) throws(S.Failure_) + where S.Element_ == Element { try self._prepend(copying: items) } @@ -478,12 +478,11 @@ extension UniqueDeque /*where Element: Copyable*/ { /// - Complexity: O(*m*), where *m* is the length of `items`, as amortized /// over many similar invocations on the same deque. @_alwaysEmitIntoClient - public mutating func prepend< - S: Iterable_ & Sequence - >( + public mutating func prepend>( copying items: borrowing S - ) { - self._prepend(copying: items) + ) throws(S.Failure_) + where S.Element_ == Element { + try self._prepend(copying: items) } /// Copies the elements of a borrowing sequence to the end of this deque. @@ -497,12 +496,11 @@ extension UniqueDeque /*where Element: Copyable*/ { /// - Complexity: O(*m*), where *m* is the length of `items` when amortized /// over many similar invocations on the same deque. @_alwaysEmitIntoClient - public mutating func prepend< - S: Iterable_ & Collection - >( + public mutating func prepend>( copying items: borrowing S - ) { - self._prepend(copying: items, exactCount: items.count) + ) throws(S.Failure_) + where S.Element_ == Element { + try self._prepend(copying: items, exactCount: items.count) } /// Copies the elements of a container to the end of this deque.