[Router] added static requirement optimization to php matcher dumper

This PR attempts to apply #6838 suggestion.
@Tobion could you please take a look and tell me what you think?

This comment should be taken in account https://github.com/symfony/symfony/issues/6838#issuecomment-21033208, this optimization could be performed by the `RouteCompiler` but it would require #5410 to be fixed (which may never happen).

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| License       | MIT