title: How to use PHP function or method arguments in any order?
body: <p>Lets say I define class with method like this:</p>
  
  <pre><code>class Test {
      public function doStuff($a, $b, $c) {
      // -- Do stuff --
      }
  }
  </code></pre>
  
  <p>Is it possible to use this method but with arguments in different order, like this:</p>
  
  <pre><code>$test = new Test();
  $test-&gt;doStuff($b, $c, $a);
  </code></pre>
  
  <p>They would have the same names, but just different order.</p>
  
  <p>I see Symfony2 can do it with its dispatcher, you can use arguments in any order you want.
  Link: <a href="http://symfony.com/doc/2.0/book/controller.html#route-parameters-as-controller-arguments">Symfony2 controller can do it</a></p>
  
  <p>The question is, how to make this work? How can Symfony2 invoke appropriate action controller, that can then accept arguments in any order you like?</p>
  
  <p>Edit:
  I cant use arrays, and I do know that php does not use named arguments. But somehow Symfony2 manage to do it.</p>