mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
stdlib: Dictionary, Set: stop overallocating the bitmap
The 'sizeInWords(forSizeInBits:)' function was supposed to return the size in words, but returned the size in bits, overallocating the bitmap by a factor of 32 or 64, depending on the platform.
This commit is contained in:
@@ -41,8 +41,7 @@ UnsafeBitMapTests.test("wordIndex(_:), bitIndex(_:)") {
|
||||
#endif
|
||||
}
|
||||
|
||||
UnsafeBitMapTests.test("sizeInWords(forSizeInBits:)")
|
||||
.xfail(.always("the API is buggy")).code {
|
||||
UnsafeBitMapTests.test("sizeInWords(forSizeInBits:)") {
|
||||
expectEqual(0, _UnsafeBitMap.sizeInWords(forSizeInBits: 0))
|
||||
#if arch(i386) || arch(arm)
|
||||
for i in 1...32 {
|
||||
|
||||
Reference in New Issue
Block a user