symfony/symfony — pull request #5326 by Tobion (2012-08-23 08:43:11+00:00)
Title: [Routing] removed cyclic reference Route<->CompiledRoute

BC break: yes

I think we should remove this proxy behavior from CompiledRoute. Cyclic references are often not a good idea and in this case it doesn't even make sense. It's like an integrated decompiler ^^ when going from CompiledRoute -> Route.

It also conflicts with the single responsibility principle in OOP design as you would need to change the CompiledRoute class whenever you change the Route class.

It also mitigates problems like
```
$compiled = $route->compile();
// $route is change by some other layer
$compiled->getRoute(); // is not in synch with $compiled anymore although this getter makes us believe that
```