<div dir="ltr">The release notes of Xcode 8.1 beta 3 said:<div>&gt; <span style="font-size:11pt;font-family:myriadsetpro">Two types have been added to the Swift standard library: </span><span style="font-size:9pt;font-family:menlo;color:rgb(102,102,102)">UnsafeRawBufferPointer </span><span style="font-size:11pt;font-family:myriadsetpro">and
</span><span style="font-size:9pt;font-family:menlo;color:rgb(102,102,102)">UnsafeMutableRawBufferPointer</span><span style="font-size:11pt;font-family:myriadsetpro">.</span></div><div><br></div><div>But I&#39;m getting errors on building sample codes in release notes:</div><div>```</div><div><p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(52,188,38)"><b>➜  </b></span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(51,187,200)"><b>9:10:46 </b></span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(82,48,225)"><b> </b></span><span style="font-variant-ligatures:no-common-ligatures">DEVELOPER_DIR=/Applications/<wbr>Xcode-beta.app swift</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures">Welcome to Apple Swift version 3.0.1 (swiftlang-800.0.56 clang-800.0.42). Type :help for assistance.</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(169,169,169)">  1&gt; </span><span style="font-variant-ligatures:no-common-ligatures">struct Header { </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(169,169,169)">  2. </span><span style="font-variant-ligatures:no-common-ligatures">    var x: Int </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(169,169,169)">  3. </span><span style="font-variant-ligatures:no-common-ligatures">    var y: Float </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(169,169,169)"><span style="font-variant-ligatures:no-common-ligatures">  4. </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">} </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(169,169,169)"><span style="font-variant-ligatures:no-common-ligatures">  5. </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"> </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(169,169,169)">  6. </span><span style="font-variant-ligatures:no-common-ligatures">var header = Header(x: 0, y: 0.0) </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(169,169,169)">  7. </span><span style="font-variant-ligatures:no-common-ligatures">var byteBuffer = [UInt8]() </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(169,169,169)">  8. </span><span style="font-variant-ligatures:no-common-ligatures">withUnsafeBytes(of: &amp;header) { (bytes: UnsafeRawBufferPointer) in </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(169,169,169)">  9. </span><span style="font-variant-ligatures:no-common-ligatures">    byteBuffer += bytes </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(169,169,169)"><span style="font-variant-ligatures:no-common-ligatures"> 10. </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">} </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(169,169,169)"><span style="font-variant-ligatures:no-common-ligatures"> 11. </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"> </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(169,169,169)"> 12. </span><span style="font-variant-ligatures:no-common-ligatures">let intArray = [1, 2, 3] </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(169,169,169)"><span style="font-variant-ligatures:no-common-ligatures"> 13. </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"> </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(169,169,169)"> 14. </span><span style="font-variant-ligatures:no-common-ligatures">intArray.withUnsafeBytes { (bytes: UnsafeRawBufferPointer) in </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(169,169,169)"> 15. </span><span style="font-variant-ligatures:no-common-ligatures">    byteBuffer += bytes </span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(169,169,169)"><span style="font-variant-ligatures:no-common-ligatures"> 16. </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">}</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures">error: repl.swift:8:1: error: use of unresolved identifier &#39;withUnsafeBytes&#39;</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures">withUnsafeBytes(of: &amp;header) { (bytes: UnsafeRawBufferPointer) in</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures">^~~~~~~~~~~~~~~</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0);min-height:13px"><span style="font-variant-ligatures:no-common-ligatures"></span><br></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures">error: repl.swift:8:40: error: use of undeclared type &#39;UnsafeRawBufferPointer&#39;</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures">withUnsafeBytes(of: &amp;header) { (bytes: UnsafeRawBufferPointer) in</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures">                                       ^~~~~~~~~~~~~~~~~~~~~~</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0);min-height:13px"><span style="font-variant-ligatures:no-common-ligatures"></span><br></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures">error: repl.swift:14:36: error: use of undeclared type &#39;UnsafeRawBufferPointer&#39;</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures">intArray.withUnsafeBytes { (bytes: UnsafeRawBufferPointer) in</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-variant-ligatures:no-common-ligatures">                                   ^~~~~~~~~~~~~~~~~~~~~~</span></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0);min-height:13px"><span style="font-variant-ligatures:no-common-ligatures"></span><br></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0);min-height:13px"><span style="font-variant-ligatures:no-common-ligatures"></span><br></p>
<p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(169,169,169)"><span style="font-variant-ligatures:no-common-ligatures">  1&gt; </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"> </span></p><p style="margin:0px;font-size:11px;line-height:normal;font-family:menlo;color:rgb(0,0,0)"><span style="font-family:arial,sans-serif;font-size:small">```</span><br></p></div><div><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"><br></span></div><div><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">Am I missing something needed for using them?</span></div><div><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">Thanks,</span></div><div><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"><br></span></div><div><font color="#000000">Norio Nomura @norio_nomura</font></div><div><font color="#000000"><br></font></div></div>