     /// Remove and return the first element if the deque isn't empty; otherwise return nil.
     ///
     /// - Complexity: O(1) if storage isn't shared with another live deque; otherwise O(`count`).
+    @discardableResult
     public mutating func popFirst() -> Element? {
         return buffer.popFirst()
     }

        self.count += 1
    }

    internal func popLast() -> Element? {
        guard count > 0 else { return nil }
        let lastIndex = bufferIndex(forDequeIndex: count - 1)

    ///
    /// - Requires: `count > 0`
    /// - Complexity: O(1) if storage isn't shared with another live deque; otherwise O(`count`).
    @discardableResult
    public mutating func removeLast() -> Element {
        precondition(count > 0)
        return buffer.popLast()!
