3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php //var_dump(false); /*preg_match('@^(?:http://)?([^/]+)@i','http://www.php.net/index.html',$matches); ${"a"} = $matches[1]; &$a = 12; echo &$a; var_export(${"a"});*/ /*echo ${"a"};*/ /*trait Foo { private $name = '123'; } class Bar { //use Foo; private static $name = '321'; public static function getName(){return static::$name;} } */ /*echo sprintf(' "%04d"', 1);*/ /* $num = array('11' , '12', '13'); foreach ($num as $val) { $val++; } print_r($num);*/ /* class Foo extends Bar{private static $name='123';} $bar = new Foo(); $bar::getName();*/ /*echo false; */ class Faz {}// $i = new Faz(); echo $i->t;/* class Baz extends Faz {} interface Foo {public function du(Faz $param);} class A implements Foo { public function du(Baz $param){ echo false; } } $c = new A(); $c->du(new Baz()); /* $i = 5; echo $i++; echo $i;*/ /* namespace Bar; function strlen($string){return 5;} namespace Foo; use Bar; echo strlen('Baz');*/ //var_dump(array_values(ksort(array('re'=>'asd', '3'=>'asda')))); //echo true;
based on 1fdn0
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = -2
filename:       /in/caf84
function name:  (null)
number of ops:  16
compiled vars:  !0 = $c
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  40     0  E >   NOP                                                      
  42     1        NOP                                                      
         2        NOP                                                      
  44     3        NOP                                                      
  46     4        DECLARE_CLASS                                    $5      '%00a%2Fin%2Fcaf840x7f908b524306', 'a'
         5        ADD_INTERFACE                                            $5, 'Foo'
         6        VERIFY_ABSTRACT_CLASS                                    $5
  52     7        NEW                                              $6      :0
         8        DO_FCALL                                      0          
         9        ASSIGN                                                   !0, $6
  53    10        INIT_METHOD_CALL                                         !0, 'du'
        11        NEW                                              $9      :4
        12        DO_FCALL                                      0          
        13        SEND_VAR_NO_REF                               0          $9
        14        DO_FCALL                                      0          
        15      > RETURN                                                   1

Class Faz: [no user functions]
Class Baz: [no user functions]
Class Foo:
Function du:
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = -2
filename:       /in/caf84
function name:  du
number of ops:  2
compiled vars:  !0 = $param
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  44     0  E >   RECV                                             !0      
         1      > RETURN                                                   null

End of function du

End of class Foo.

Class A:
Function du:
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = -2
filename:       /in/caf84
function name:  du
number of ops:  3
compiled vars:  !0 = $param
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  48     0  E >   RECV                                             !0      
  49     1        ECHO                                                     <false>
  50     2      > RETURN                                                   null

End of function du

End of class A.

Generated using Vulcan Logic Dumper, using php 7.1.0