Permalink
Browse files

Add test for #62907

  • Loading branch information...
1 parent 383eafe commit e24194d15755fc574a39df1bc3a572394627f847 @laruence laruence committed Aug 26, 2012
Showing with 24 additions and 0 deletions.
  1. +24 −0 Zend/tests/bug62907.phpt
View
@@ -0,0 +1,24 @@
+--TEST--
+Bug #62907 (Double free when use traits)
+--XFAIL--
+bug is not fixed yet
+--FILE--
+<?php
+function __autoload($name) {
+ if ($name == "B") {
+ eval ("abstract class B extends A { }");
+ } else if ($name == "A") {
+ eval ("abstract class A { use T { T::__construct as __asconstruct; }}");
+ } else if ($name == "T") {
+ eval ("trait T { public function __construct() { } }");
+ }
+ return TRUE;
+}
+
+class C extends B {
+ public function __construct() {
+ }
+}
+echo "okey";
+--EXPECT--
+okey

0 comments on commit e24194d

Please sign in to comment.