title: PHP foreach that returns keys only
body: <p>Theoretical question that perhaps does not make any sense but still, maybe there is a clever answer.</p>
  
  <p>I want to iterate through array and get its keys and to something with them. A quick example of what I do:</p>
  
  <pre><code>foreach($array as $key =&gt; $value) {
      $other_array[$key] = 'something';
  }
  </code></pre>
  
  <p>Now, <code>PHP Mess Detector</code> screams that <code>$value</code> is unused in this scope. Therefore I was thinking that perhaps this is not the best way to access <code>keys</code> of my <code>array</code>. </p>
  
  <p>Any idea how to do it without unnecessarily taking out <code>values</code> out of my <code>array</code>? Does it have any significant performance impact ... or perhaps I am just being paranoid and should carry on without wasting anyone's time with stupid questions :).</p>