mirror of
https://github.com/php/php-src.git
synced 2025-08-18 06:58:55 +02:00

PHP requires integer typehints to be written "int" and does not allow "integer" as an alias. This changes type error messages to match the actual type name and avoids confusing messages like "must be of the type integer, integer given".
31 lines
418 B
PHP
31 lines
418 B
PHP
--TEST--
|
|
ReflectionClass::export() - array constants
|
|
--FILE--
|
|
<?php
|
|
Class A {
|
|
const A = 8;
|
|
const B = ["a", "b"];
|
|
}
|
|
ReflectionClass::export("A");
|
|
?>
|
|
--EXPECTF--
|
|
Class [ <user> class A ] {
|
|
@@ %s 2-5
|
|
|
|
- Constants [2] {
|
|
Constant [ public int A ] { 8 }
|
|
Constant [ public array B ] { Array }
|
|
}
|
|
|
|
- Static properties [0] {
|
|
}
|
|
|
|
- Static methods [0] {
|
|
}
|
|
|
|
- Properties [0] {
|
|
}
|
|
|
|
- Methods [0] {
|
|
}
|
|
}
|