[NFC] Fixing some stdlib unused warnings

This commit is contained in:
LucianoAlmeida
2022-02-20 18:18:35 -03:00
parent b0043966cd
commit 09bf4cb6d1
3 changed files with 4 additions and 4 deletions

View File

@@ -154,7 +154,7 @@ internal struct _CocoaArrayWrapper: RandomAccessCollection {
guard buffer.count > 0 else { return (makeIterator(), 0) }
let start = buffer.baseAddress!
let c = Swift.min(self.count, buffer.count)
let end = _copyContents(subRange: 0 ..< c, initializing: start)
_ = _copyContents(subRange: 0 ..< c, initializing: start)
return (IndexingIterator(_elements: self, _position: c), c)
}
}

View File

@@ -822,7 +822,7 @@ internal struct _ContiguousArrayBuffer<Element>: _ArrayBufferProtocol {
// class type to use _ContiguousArrayStorage<AnyObject> when we bridge
// to objective-c we need to set the correct Element type so that when
// we bridge back we can use O(1) bridging i.e we can adopt the storage.
_swift_setClassMetadata(_ContiguousArrayStorage<Element>.self,
_ = _swift_setClassMetadata(_ContiguousArrayStorage<Element>.self,
onObject: _storage)
}
return _storage

View File

@@ -590,7 +590,7 @@ private func _wideMaskedShiftLeft<F: FixedWidthInteger>(
var high = lhs.high &<< F(rhs)
let rollover = F.Magnitude(F.bitWidth) &- rhs
high |= F(truncatingIfNeeded: lhs.low &>> rollover)
var low = lhs.low &<< rhs
let low = lhs.low &<< rhs
return (high, low)
}