3v4l.org

run code in 300+ PHP versions simultaneously
<?php use Symfony\Component\Finder\Finder; class BonesSingleton { public static $instance; public static function getInstance() { if (null === static::$instance) { static::$instance = new static(); } return static::$instance; } protected function __construct() { } private function __clone() { } private function __wakeup() { } } class TwigSingleton extends BonesSingleton { public $twig = false; public $templates = array(); protected function __construct() { $this->getTemplates(); $loader = new Twig_Loader_Array($this->templates); $twigEnv = new Twig_Environment($loader, array('debug' => true)); $imageFunc = new Twig_SimpleFunction('imagesrc', 'show_image', array('is_safe' => array('html'))); $doShortcodeFunc = new Twig_SimpleFunction('do_shortcode', function ($content, $ignore_html = false) { return do_shortcode($content, $ignore_html); }, array('is_safe' => array('html'))); $doBlockFunc = new Twig_SimpleFunction('localize_url', function ($url, $ignore_html = false) { return localize_url($url); }, array('is_safe' => array('html'))); $addEncoFunc = new Twig_SimpleFunction('add_enc',function($redirect_page){ return '<input type="hidden" name="uenc" value="'. Mage::helper('core')->urlEncode(Mage::helper('cms/page')->getPageUrl($redirect_page)).'"/>'; }, array('is_safe' => array('html'))); $twigEnv->addExtension(new Twig_Extension_Debug()); $twigEnv->addFunction($imageFunc); $twigEnv->addFunction($doShortcodeFunc); $twigEnv->addFunction($doBlockFunc); $twigEnv->addFunction($addEncoFunc); $this->twig = $twigEnv; } public function getTwig() { return $this->twig; } public function getTemplates() { //execute all the pattern portfolio parts $this->get_templates_for('04-pages', 'pages'); $this->get_templates_for('03-templates', 'templates'); $this->get_templates_for('02-organisms', 'organisms'); $this->get_templates_for('01-molecules', 'molecules'); $this->get_templates_for('00-atoms', 'atoms'); } private function get_templates_for($folder, $prefix) { $pages = new Finder(); $pages->files()->in(PATTERNS_TEMPLATES . '/' . $folder)->name('*.twig'); foreach ($pages as $file) { $this->templates[$this->prepare_name($file, $prefix . '-')] = $file->getContents(); } } private function prepare_name($file, $prefix = '') { return $prefix . preg_replace('/^[_0-9\-]*/', '', $file->getBasename('.twig')); } } define('PATTERNS_TEMPLATES', dirname(ABSPATH) . '/skin/frontend/sophiehulme/uk/styleguide/source/_patterns'); function create_sh_link($link) { return $link; } function show_image($img, $size, $title = false, $classes = '', $animTarget = false, $lazyload) { $imgHtml = '<img class="block image auto-height js-anim-image ' . $classes . '" width="' . $img['width'] . '" height="' . $img['height'] . '" alt="' . $img['name'] . '" srcset="' . get_image_group_srcset($img, $size) . '"' . ($animTarget ? ' data-anim-target="' . $animTarget . '"' : '') . ' sizes="'. get_image_group_size($size).'">'; if ($title && is_string($title)) { return "<figure class='figure'> $imgHtml <figcaption class='figcaption t-header-small psy1'>$title</figcaption> </figure>"; } else { echo $imgHtml; } } function date_to_unix($date) { $dateTime = DateTime::createFromFormat('d/m/Y', $date); return $dateTime->getTimestamp(); } function should_be_visible($from, $to) { $currentTime = strtotime('now'); return (date_to_unix($from) < $currentTime && $currentTime < date_to_unix($to)); } //small singleton (Yeah I know) //lazy person loader function twig_render($name, $data, $debug) { return TwigSingleton::getInstance()->getTwig()->render($name, $data); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  (null)
number of ops:  10
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   92     0  E >   INIT_FCALL                                               'define'
          1        SEND_VAL                                                 'PATTERNS_TEMPLATES'
          2        INIT_FCALL                                               'dirname'
          3        FETCH_CONSTANT                                   ~0      'ABSPATH'
          4        SEND_VAL                                                 ~0
          5        DO_ICALL                                         $1      
          6        CONCAT                                           ~2      $1, '%2Fskin%2Ffrontend%2Fsophiehulme%2Fuk%2Fstyleguide%2Fsource%2F_patterns'
          7        SEND_VAL                                                 ~2
          8        DO_ICALL                                                 
  124     9      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2F4Ocuo%3A42%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  {closure}
number of ops:  8
compiled vars:  !0 = $content, !1 = $ignore_html
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   42     0  E >   RECV                                             !0      
          1        RECV_INIT                                        !1      <false>
   43     2        INIT_FCALL_BY_NAME                                       'do_shortcode'
          3        SEND_VAR_EX                                              !0
          4        SEND_VAR_EX                                              !1
          5        DO_FCALL                                      0  $2      
          6      > RETURN                                                   $2
   44     7*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2F4Ocuo%3A42%240

Function %00%7Bclosure%7D%2Fin%2F4Ocuo%3A45%241:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  {closure}
number of ops:  7
compiled vars:  !0 = $url, !1 = $ignore_html
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   45     0  E >   RECV                                             !0      
          1        RECV_INIT                                        !1      <false>
   46     2        INIT_FCALL_BY_NAME                                       'localize_url'
          3        SEND_VAR_EX                                              !0
          4        DO_FCALL                                      0  $2      
          5      > RETURN                                                   $2
   47     6*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2F4Ocuo%3A45%241

Function %00%7Bclosure%7D%2Fin%2F4Ocuo%3A48%242:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  {closure}
number of ops:  17
compiled vars:  !0 = $redirect_page
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   48     0  E >   RECV                                             !0      
   49     1        INIT_STATIC_METHOD_CALL                                  'Mage', 'helper'
          2        SEND_VAL_EX                                              'core'
          3        DO_FCALL                                      0  $1      
          4        INIT_METHOD_CALL                                         $1, 'urlEncode'
          5        INIT_STATIC_METHOD_CALL                                  'Mage', 'helper'
          6        SEND_VAL_EX                                              'cms%2Fpage'
          7        DO_FCALL                                      0  $2      
          8        INIT_METHOD_CALL                                         $2, 'getPageUrl'
          9        SEND_VAR_EX                                              !0
         10        DO_FCALL                                      0  $3      
         11        SEND_VAR_NO_REF_EX                                       $3
         12        DO_FCALL                                      0  $4      
         13        CONCAT                                           ~5      '%3Cinput+type%3D%22hidden%22+name%3D%22uenc%22+value%3D%22', $4
         14        CONCAT                                           ~6      ~5, '%22%2F%3E'
         15      > RETURN                                                   ~6
   50    16*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2F4Ocuo%3A48%242

Function create_sh_link:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  create_sh_link
number of ops:  3
compiled vars:  !0 = $link
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   94     0  E >   RECV                                             !0      
   95     1      > RETURN                                                   !0
   96     2*     > RETURN                                                   null

End of function create_sh_link

Function show_image:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 24, Position 2 = 28
Branch analysis from position: 24
1 jumps found. (Code = 42) Position 1 = 29
Branch analysis from position: 29
2 jumps found. (Code = 46) Position 1 = 38, Position 2 = 40
Branch analysis from position: 38
2 jumps found. (Code = 43) Position 1 = 41, Position 2 = 48
Branch analysis from position: 41
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 48
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 40
Branch analysis from position: 28
2 jumps found. (Code = 46) Position 1 = 38, Position 2 = 40
Branch analysis from position: 38
Branch analysis from position: 40
filename:       /in/4Ocuo
function name:  show_image
number of ops:  50
compiled vars:  !0 = $img, !1 = $size, !2 = $title, !3 = $classes, !4 = $animTarget, !5 = $lazyload, !6 = $imgHtml
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   98     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV_INIT                                        !2      <false>
          3        RECV_INIT                                        !3      ''
          4        RECV_INIT                                        !4      <false>
          5        RECV                                             !5      
   99     6        CONCAT                                           ~7      '%3Cimg+class%3D%22block+image+auto-height+js-anim-image+', !3
          7        CONCAT                                           ~8      ~7, '%22+width%3D%22'
          8        FETCH_DIM_R                                      ~9      !0, 'width'
          9        CONCAT                                           ~10     ~8, ~9
         10        CONCAT                                           ~11     ~10, '%22+height%3D%22'
         11        FETCH_DIM_R                                      ~12     !0, 'height'
         12        CONCAT                                           ~13     ~11, ~12
         13        CONCAT                                           ~14     ~13, '%22+alt%3D%22'
         14        FETCH_DIM_R                                      ~15     !0, 'name'
         15        CONCAT                                           ~16     ~14, ~15
         16        CONCAT                                           ~17     ~16, '%22+srcset%3D%22'
         17        INIT_FCALL_BY_NAME                                       'get_image_group_srcset'
         18        SEND_VAR_EX                                              !0
         19        SEND_VAR_EX                                              !1
         20        DO_FCALL                                      0  $18     
         21        CONCAT                                           ~19     ~17, $18
         22        CONCAT                                           ~20     ~19, '%22'
         23      > JMPZ                                                     !4, ->28
         24    >   CONCAT                                           ~21     '+data-anim-target%3D%22', !4
         25        CONCAT                                           ~22     ~21, '%22'
         26        QM_ASSIGN                                        ~23     ~22
         27      > JMP                                                      ->29
         28    >   QM_ASSIGN                                        ~23     ''
         29    >   CONCAT                                           ~24     ~20, ~23
         30        CONCAT                                           ~25     ~24, '+sizes%3D%22'
         31        INIT_FCALL_BY_NAME                                       'get_image_group_size'
         32        SEND_VAR_EX                                              !1
         33        DO_FCALL                                      0  $26     
         34        CONCAT                                           ~27     ~25, $26
         35        CONCAT                                           ~28     ~27, '%22%3E'
         36        ASSIGN                                                   !6, ~28
  100    37      > JMPZ_EX                                          ~30     !2, ->40
         38    >   TYPE_CHECK                                   64  ~31     !2
         39        BOOL                                             ~30     ~31
         40    > > JMPZ                                                     ~30, ->48
  101    41    >   ROPE_INIT                                     5  ~33     '%3Cfigure+class%3D%27figure%27%3E%0A++++'
  102    42        ROPE_ADD                                      1  ~33     ~33, !6
         43        ROPE_ADD                                      2  ~33     ~33, '%0A++++%3Cfigcaption+class%3D%27figcaption+t-header-small+psy1%27%3E'
  103    44        ROPE_ADD                                      3  ~33     ~33, !2
         45        ROPE_END                                      4  ~32     ~33, '%3C%2Ffigcaption%3E+++++++++++++%0A%3C%2Ffigure%3E'
         46      > RETURN                                                   ~32
         47*       JMP                                                      ->49
  106    48    >   ECHO                                                     !6
  108    49      > RETURN                                                   null

End of function show_image

Function date_to_unix:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  date_to_unix
number of ops:  10
compiled vars:  !0 = $date, !1 = $dateTime
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  110     0  E >   RECV                                             !0      
  111     1        INIT_STATIC_METHOD_CALL                                  'DateTime', 'createFromFormat'
          2        SEND_VAL                                                 'd%2Fm%2FY'
          3        SEND_VAR                                                 !0
          4        DO_FCALL                                      0  $2      
          5        ASSIGN                                                   !1, $2
  112     6        INIT_METHOD_CALL                                         !1, 'getTimestamp'
          7        DO_FCALL                                      0  $4      
          8      > RETURN                                                   $4
  113     9*     > RETURN                                                   null

End of function date_to_unix

Function should_be_visible:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 11, Position 2 = 16
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 16
filename:       /in/4Ocuo
function name:  should_be_visible
number of ops:  18
compiled vars:  !0 = $from, !1 = $to, !2 = $currentTime
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  115     0  E >   RECV                                             !0      
          1        RECV                                             !1      
  116     2        INIT_FCALL                                               'strtotime'
          3        SEND_VAL                                                 'now'
          4        DO_ICALL                                         $3      
          5        ASSIGN                                                   !2, $3
  117     6        INIT_FCALL                                               'date_to_unix'
          7        SEND_VAR                                                 !0
          8        DO_FCALL                                      0  $5      
          9        IS_SMALLER                                       ~6      $5, !2
         10      > JMPZ_EX                                          ~6      ~6, ->16
         11    >   INIT_FCALL                                               'date_to_unix'
         12        SEND_VAR                                                 !1
         13        DO_FCALL                                      0  $7      
         14        IS_SMALLER                                       ~8      !2, $7
         15        BOOL                                             ~6      ~8
         16    > > RETURN                                                   ~6
  118    17*     > RETURN                                                   null

End of function should_be_visible

Function twig_render:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  twig_render
number of ops:  13
compiled vars:  !0 = $name, !1 = $data, !2 = $debug
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  122     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
  123     3        INIT_STATIC_METHOD_CALL                                  'TwigSingleton', 'getInstance'
          4        DO_FCALL                                      0  $3      
          5        INIT_METHOD_CALL                                         $3, 'getTwig'
          6        DO_FCALL                                      0  $4      
          7        INIT_METHOD_CALL                                         $4, 'render'
          8        SEND_VAR_EX                                              !0
          9        SEND_VAR_EX                                              !1
         10        DO_FCALL                                      0  $5      
         11      > RETURN                                                   $5
  124    12*     > RETURN                                                   null

End of function twig_render

Class BonesSingleton:
Function getinstance:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 7
Branch analysis from position: 3
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/4Ocuo
function name:  getInstance
number of ops:  10
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   FETCH_STATIC_PROP_R          unknown             ~0      'instance'
          1        TYPE_CHECK                                    2          ~0
          2      > JMPZ                                                     ~1, ->7
   11     3    >   NEW                          static              $3      
          4        DO_FCALL                                      0          
          5        ASSIGN_STATIC_PROP                                       'instance'
          6        OP_DATA                                                  $3
   14     7    >   FETCH_STATIC_PROP_R          unknown             ~5      'instance'
          8      > RETURN                                                   ~5
   15     9*     > RETURN                                                   null

End of function getinstance

Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  __construct
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E > > RETURN                                                   null

End of function __construct

Function __clone:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  __clone
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   23     0  E > > RETURN                                                   null

End of function __clone

Function __wakeup:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  __wakeup
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   27     0  E > > RETURN                                                   null

End of function __wakeup

End of class BonesSingleton.

Class TwigSingleton:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  __construct
number of ops:  60
compiled vars:  !0 = $loader, !1 = $twigEnv, !2 = $imageFunc, !3 = $doShortcodeFunc, !4 = $doBlockFunc, !5 = $addEncoFunc
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   38     0  E >   INIT_METHOD_CALL                                         'getTemplates'
          1        DO_FCALL                                      0          
   39     2        NEW                                              $7      'Twig_Loader_Array'
          3        CHECK_FUNC_ARG                                           
          4        FETCH_OBJ_FUNC_ARG                               $8      'templates'
          5        SEND_FUNC_ARG                                            $8
          6        DO_FCALL                                      0          
          7        ASSIGN                                                   !0, $7
   40     8        NEW                                              $11     'Twig_Environment'
          9        SEND_VAR_EX                                              !0
         10        SEND_VAL_EX                                              <array>
         11        DO_FCALL                                      0          
         12        ASSIGN                                                   !1, $11
   41    13        NEW                                              $14     'Twig_SimpleFunction'
         14        SEND_VAL_EX                                              'imagesrc'
         15        SEND_VAL_EX                                              'show_image'
         16        SEND_VAL_EX                                              <array>
         17        DO_FCALL                                      0          
         18        ASSIGN                                                   !2, $14
   42    19        NEW                                              $17     'Twig_SimpleFunction'
         20        SEND_VAL_EX                                              'do_shortcode'
         21        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2F4Ocuo%3A42%240'
   44    22        SEND_VAL_EX                                              ~18
         23        SEND_VAL_EX                                              <array>
         24        DO_FCALL                                      0          
   42    25        ASSIGN                                                   !3, $17
   45    26        NEW                                              $21     'Twig_SimpleFunction'
         27        SEND_VAL_EX                                              'localize_url'
         28        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2F4Ocuo%3A45%241'
   47    29        SEND_VAL_EX                                              ~22
         30        SEND_VAL_EX                                              <array>
         31        DO_FCALL                                      0          
   45    32        ASSIGN                                                   !4, $21
   48    33        NEW                                              $25     'Twig_SimpleFunction'
         34        SEND_VAL_EX                                              'add_enc'
         35        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2F4Ocuo%3A48%242'
   50    36        SEND_VAL_EX                                              ~26
         37        SEND_VAL_EX                                              <array>
         38        DO_FCALL                                      0          
   48    39        ASSIGN                                                   !5, $25
   51    40        INIT_METHOD_CALL                                         !1, 'addExtension'
         41        NEW                                              $29     'Twig_Extension_Debug'
         42        DO_FCALL                                      0          
         43        SEND_VAR_NO_REF_EX                                       $29
         44        DO_FCALL                                      0          
   52    45        INIT_METHOD_CALL                                         !1, 'addFunction'
         46        SEND_VAR_EX                                              !2
         47        DO_FCALL                                      0          
   53    48        INIT_METHOD_CALL                                         !1, 'addFunction'
         49        SEND_VAR_EX                                              !3
         50        DO_FCALL                                      0          
   54    51        INIT_METHOD_CALL                                         !1, 'addFunction'
         52        SEND_VAR_EX                                              !4
         53        DO_FCALL                                      0          
   55    54        INIT_METHOD_CALL                                         !1, 'addFunction'
         55        SEND_VAR_EX                                              !5
         56        DO_FCALL                                      0          
   57    57        ASSIGN_OBJ                                               'twig'
         58        OP_DATA                                                  !1
   58    59      > RETURN                                                   null

End of function __construct

Function gettwig:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  getTwig
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   61     0  E >   FETCH_OBJ_R                                      ~0      'twig'
          1      > RETURN                                                   ~0
   62     2*     > RETURN                                                   null

End of function gettwig

Function gettemplates:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  getTemplates
number of ops:  21
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   66     0  E >   INIT_METHOD_CALL                                         'get_templates_for'
          1        SEND_VAL_EX                                              '04-pages'
          2        SEND_VAL_EX                                              'pages'
          3        DO_FCALL                                      0          
   68     4        INIT_METHOD_CALL                                         'get_templates_for'
          5        SEND_VAL_EX                                              '03-templates'
          6        SEND_VAL_EX                                              'templates'
          7        DO_FCALL                                      0          
   70     8        INIT_METHOD_CALL                                         'get_templates_for'
          9        SEND_VAL_EX                                              '02-organisms'
         10        SEND_VAL_EX                                              'organisms'
         11        DO_FCALL                                      0          
   72    12        INIT_METHOD_CALL                                         'get_templates_for'
         13        SEND_VAL_EX                                              '01-molecules'
         14        SEND_VAL_EX                                              'molecules'
         15        DO_FCALL                                      0          
   74    16        INIT_METHOD_CALL                                         'get_templates_for'
         17        SEND_VAL_EX                                              '00-atoms'
         18        SEND_VAL_EX                                              'atoms'
         19        DO_FCALL                                      0          
   75    20      > RETURN                                                   null

End of function gettemplates

Function get_templates_for:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 17, Position 2 = 29
Branch analysis from position: 17
2 jumps found. (Code = 78) Position 1 = 18, Position 2 = 29
Branch analysis from position: 18
1 jumps found. (Code = 42) Position 1 = 17
Branch analysis from position: 17
Branch analysis from position: 29
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 29
filename:       /in/4Ocuo
function name:  get_templates_for
number of ops:  31
compiled vars:  !0 = $folder, !1 = $prefix, !2 = $pages, !3 = $file
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   77     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   78     2        NEW                                              $4      'Symfony%5CComponent%5CFinder%5CFinder'
          3        DO_FCALL                                      0          
          4        ASSIGN                                                   !2, $4
   79     5        INIT_METHOD_CALL                                         !2, 'files'
          6        DO_FCALL                                      0  $7      
          7        INIT_METHOD_CALL                                         $7, 'in'
          8        FETCH_CONSTANT                                   ~8      'PATTERNS_TEMPLATES'
          9        CONCAT                                           ~9      ~8, '%2F'
         10        CONCAT                                           ~10     ~9, !0
         11        SEND_VAL_EX                                              ~10
         12        DO_FCALL                                      0  $11     
         13        INIT_METHOD_CALL                                         $11, 'name'
         14        SEND_VAL_EX                                              '%2A.twig'
         15        DO_FCALL                                      0          
   80    16      > FE_RESET_R                                       $13     !2, ->29
         17    > > FE_FETCH_R                                               $13, !3, ->29
   81    18    >   INIT_METHOD_CALL                                         'prepare_name'
         19        SEND_VAR_EX                                              !3
         20        CONCAT                                           ~15     !1, '-'
         21        SEND_VAL_EX                                              ~15
         22        DO_FCALL                                      0  $16     
         23        INIT_METHOD_CALL                                         !3, 'getContents'
         24        DO_FCALL                                      0  $18     
         25        FETCH_OBJ_W                                      $14     'templates'
         26        ASSIGN_DIM                                               $14, $16
         27        OP_DATA                                                  $18
   80    28      > JMP                                                      ->17
         29    >   FE_FREE                                                  $13
   83    30      > RETURN                                                   null

End of function get_templates_for

Function prepare_name:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Ocuo
function name:  prepare_name
number of ops:  13
compiled vars:  !0 = $file, !1 = $prefix
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   85     0  E >   RECV                                             !0      
          1        RECV_INIT                                        !1      ''
   87     2        INIT_FCALL                                               'preg_replace'
          3        SEND_VAL                                                 '%2F%5E%5B_0-9%5C-%5D%2A%2F'
          4        SEND_VAL                                                 ''
          5        INIT_METHOD_CALL                                         !0, 'getBasename'
          6        SEND_VAL_EX                                              '.twig'
          7        DO_FCALL                                      0  $2      
          8        SEND_VAR                                                 $2
          9        DO_ICALL                                         $3      
         10        CONCAT                                           ~4      !1, $3
         11      > RETURN                                                   ~4
   88    12*     > RETURN                      

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
200.6 ms | 1431 KiB | 23 Q