xref: /PHP-8.1/Zend/tests/enum/__callStatic.phpt (revision 269c8dac)
1--TEST--
2Enum __callStatic
3--FILE--
4<?php
5
6enum Foo {
7    public static function __callStatic(string $name, array $args)
8    {
9        return [$name, $args];
10    }
11}
12
13var_dump(Foo::bar('baz', 'qux'));
14
15?>
16--EXPECT--
17array(2) {
18  [0]=>
19  string(3) "bar"
20  [1]=>
21  array(2) {
22    [0]=>
23    string(3) "baz"
24    [1]=>
25    string(3) "qux"
26  }
27}
28