title: Meaning of const pointers as function parameters
body: <p>I have this function signature:</p>
  
  <pre><code>void myFunction(int *const ptr);
  </code></pre>
  
  <p>What's the point of the <code>const</code> keyword in this particular context?</p>
  
  <p>Even if <code>ptr</code> wasn't a <code>const</code> variable, I couldn't modify to what address it points to, because it's passed by value, so if I had another function like this:</p>
  
  <pre><code>void myAnotherFunction(int *ptr);
  </code></pre>
  
  <p>And inside its implementation did something like this:</p>
  
  <pre><code>//...
  ptr = malloc(1023);
  //...
  </code></pre>
  
  <p>This wouldn't affect the passed value (outside this function, of course).</p>
  
  <p>So the question is: what's the point of using <code>myFunction()</code> signature instead of <code>myAnotherFunction()</code> one? (beside that you get a compile-time error).</p>