1: <?php declare(strict_types = 1);
2:
3: namespace PHPStan\Type;
4:
5: /** @api */
6: class ErrorType extends MixedType
7: {
8:
9: /** @api */
10: public function __construct()
11: {
12: parent::__construct();
13: }
14:
15: public function describe(VerbosityLevel $level): string
16: {
17: return $level->handle(
18: fn (): string => parent::describe($level),
19: fn (): string => parent::describe($level),
20: static fn (): string => '*ERROR*',
21: );
22: }
23:
24: public function getIterableKeyType(): Type
25: {
26: return new ErrorType();
27: }
28:
29: public function getIterableValueType(): Type
30: {
31: return new ErrorType();
32: }
33:
34: public function subtract(Type $type): Type
35: {
36: return new self();
37: }
38:
39: public function equals(Type $type): bool
40: {
41: return $type instanceof self;
42: }
43:
44: }
45: