title: const correctness for structs with pointers
body: <p>I have a struct which contains some pointers. I want the value of these to be unmodifiable. But simply writing const infront doesn't make the structs members unmutable</p>
  
  <pre><code>typedef struct{
    int *x;
    int *y;
  }point;
  
  void get(const  point *p,int x, int y){
    p-&gt;x[0]=x;//&lt;- this should not be allowed
    p-&gt;y[0]=y;//&lt;- this should not be allowed
  }
  </code></pre>
  
  <p>Can someone point me in the right direction.</p>
  
  <p>EDIT:</p>
  
  <p>So it would seem that there is no simple way of using the function prototype to tell that everything belonging to the struct should be unmodifiable</p>