title: Laravel 5.1 - Call to undefined method Illuminate\View\Compilers\BladeCompiler::createPlainMatcher()
body: <p>Trying to upgrade my project from L5 to L5.1 and here is incompatibility:</p>
  
  <blockquote>
    <p>Call to undefined method
    Illuminate\View\Compilers\BladeCompiler::createPlainMatcher()</p>
  </blockquote>
  
  <p>Here's the code which cause an exception:</p>
  
  <pre><code>Blade::extend(function($view, $compiler) {
      $pattern = $compiler-&gt;createPlainMatcher('spaceless');
      return preg_replace($pattern, '$1&lt;?php ob_start(); ?&gt;$2', $view);
  });
  
  Blade::extend(function($view, $compiler) {
      $pattern = $compiler-&gt;createPlainMatcher('endspaceless');
      return preg_replace($pattern, '$1&lt;?php echo trim(preg_replace(\'/&gt;\s+&lt;/\', \'&gt;&lt;\', ob_get_clean())); ?&gt;$2', $view);
  });
  </code></pre>
  
  <p>What should I change to make this code working in Laravel 5.1?</p>