Explorar o código

alignof -> MemoryLayout<T>.alignment

Marcin Krzyżanowski %!s(int64=9) %!d(string=hai) anos
pai
achega
349486b595
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      CryptoSwiftTests/HashTests.swift

+ 1 - 1
CryptoSwiftTests/HashTests.swift

@@ -59,7 +59,7 @@ final class CryptoSwiftTests: XCTestCase {
             self.stopMeasuring()
             md.deallocate(capacity: Int(CC_MD5_DIGEST_LENGTH))
             md.deinitialize()
-            buf.deallocate(bytes: 1024 * 1024, alignedTo: alignof(UInt8.self))
+            buf.deallocate(bytes: 1024 * 1024, alignedTo: MemoryLayout<UInt8>.alignment)
         })
     }