summaryrefslogtreecommitdiff
path: root/Zend/tests/traits/bugs/alias-semantics.phpt
blob: 39eb82cbbdc4f77c489b593c49e39e6db5db533c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
--TEST--
Semantic of alias operation is to provide an additional identifier for the method body of the original method.
--FILE--
<?php
error_reporting(E_ALL);

trait THello {
  public function a() {
    echo 'A';
  }
}

class TraitsTest {
	use THello { a as b; }
}

$test = new TraitsTest();
$test->a();
$test->b();

?>
--EXPECTF--
AA