title: Silex url generator: Unable to generate
body: <p>I'm using the Silex url generator to name my routes. But the retrieval of them doesn't seem to work in different files.</p>
  
  <p>I include them first:</p>
  
  
  
  <pre class="lang-php prettyprint-override"><code>include __DIR__ . '/app/pages/bootstrap.php';
  include __DIR__ . '/app/news/bootstrap.php';
  </code></pre>
  
  <p>In the pages bootstrap I have:</p>
  
  <pre class="lang-php prettyprint-override"><code>$app-&gt;get('/admin/pages', function(Request $request) use($app){
     // code
  })-&gt;bind('admin.pages.index');
  
  echo $app['url_generator']-&gt;generate('admin.pages.index');
  </code></pre>
  
  <p>And in the news bootstrap I have:</p>
  
  <pre class="lang-php prettyprint-override"><code>$app-&gt;get('/admin/news', function(Request $request) use($app){
     // code
  })-&gt;bind('admin.news.index');
  
  echo $app['url_generator']-&gt;generate('admin.news.index');
  </code></pre>
  
  <p>It generates 'admin.pages.index' perfeclty, but for 'admin.news.index' I receive:</p>
  
  <pre class="lang-php prettyprint-override"><code>'Unable to generate a URL for the named route "admin.news.index" as such route does not exist.' 
  </code></pre>
  
  <p><strong>Observations</strong></p>
  
  <p>• When I put everything in one file, it works fine.</p>
  
  <p>• When I change the load order to:</p>
  
  <pre class="lang-php prettyprint-override"><code>include __DIR__ . '/app/news/bootstrap.php';
  include __DIR__ . '/app/pages/bootstrap.php';
  </code></pre>
  
  <p>It generates 'admin.news.index' fine, but 'admin.pages.index' fails.</p>