Swift Error: Cannot pass immutable value as inout argument: 'pChData' is a 'let' constant
<p>I have a function that looks like the following:</p>

<pre><code>func receivedData(pChData: UInt8, andLength len: CInt) {
    var receivedData: Byte = Byte()
    var receivedDataLength: CInt = 0

    memcpy(&amp;receivedData, &amp;pChData, Int(len));  // Getting the error here
    receivedDataLength = len
    AudioHandler.sharedInstance.receiverAudio(&amp;receivedData, WithLen: receivedDataLength)
}
</code></pre>

<p>Getting the error:</p>

<blockquote>
  <p>Cannot pass immutable value as inout argument: 'pChData' is a 'let' constant </p>
</blockquote>

<p><img src="https://i.stack.imgur.com/jp5RT.png" alt="Xcode screenshot"></p>

<p>Though none of the arguments which I am passing here are <code>let</code> constants. Why am I getting this?</p>