12345678910111213141516171819202122232425262728 |
- Anonymous classes
- -----
- <?php
- new class {};
- new class extends A implements B, C {};
- new class($a) extends A {
- private $a;
- public function __construct($a) {
- $this->a = $a;
- }
- };
- -----
- new class
- {
- };
- new class extends A implements B, C
- {
- };
- new class($a) extends A
- {
- private $a;
- public function __construct($a)
- {
- $this->a = $a;
- }
- };
|