]> granicus.if.org Git - php/commitdiff
Test files were fixed acording to new constructor redeclaration semantic
authorDmitry Stogov <dmitry@php.net>
Fri, 5 Mar 2004 12:18:16 +0000 (12:18 +0000)
committerDmitry Stogov <dmitry@php.net>
Fri, 5 Mar 2004 12:18:16 +0000 (12:18 +0000)
tests/classes/ctor_dtor.phpt
tests/classes/inheritance_002.phpt

index fce1c19907b832bab1a35505d0977652fc4c2b52..ea6813cc96d6e4611a5f7485385c90481e26ee54 100644 (file)
@@ -9,9 +9,6 @@ class early {
        function early() {
                echo __CLASS__ . "::" . __FUNCTION__ . "\n";
        }
-       function __construct() {
-               echo __CLASS__ . "::" . __FUNCTION__ . "\n";
-       }
        function __destruct() {
                echo __CLASS__ . "::" . __FUNCTION__ . "\n";
        }
@@ -21,9 +18,6 @@ class late {
        function __construct() {
                echo __CLASS__ . "::" . __FUNCTION__ . "\n";
        }
-       function late() {
-               echo __CLASS__ . "::" . __FUNCTION__ . "\n";
-       }
        function __destruct() {
                echo __CLASS__ . "::" . __FUNCTION__ . "\n";
        }
@@ -33,16 +27,14 @@ $t = new early();
 $t->early();
 unset($t);
 $t = new late();
-$t->late();
 //unset($t); delay to end of script
 
 echo "Done\n";
 ?>
 --EXPECTF--
-early::__construct
+early::early
 early::early
 early::__destruct
 late::__construct
-late::late
 Done
 late::__destruct
index a5688bba569b0bc487230859c73748991e05491d..cca528e29c89fa27d670640aea67e7b09064f328 100755 (executable)
@@ -21,22 +21,14 @@ class Base_php5 {
   function __construct() {
     var_dump('Base constructor');
   }
-  
-  function Base_php5() {
-    var_dump('I should not be called');
   }
-}
 
 class Child_php5 extends Base_php5 {
   function __construct() {
     var_dump('Child constructor');
     parent::__construct();
   }
-  
-  function Child_php5() {
-    var_dump('I should not be called');
   }
-}
 
 class Child_mx1 extends Base_php4 {
   function __construct() {