Home
last modified time | relevance | path

Searched refs:iterable (Results 1 – 25 of 57) sorted by relevance

123

/php-src/Zend/tests/type_declarations/iterable/
H A Diterable_004.phpt2 iterable type#004 - Parameter covariance
15 function testArray(iterable $iterable) {}
17 function testTraversable(iterable $iterable) {}
19 function testScalar(iterable $iterable) {}
24 Fatal error: Declaration of Bar::testScalar(Traversable|array $iterable) must be compatible with Fo…
H A Diterable_002.phpt2 iterable type#002 - Default values
6 function foo(iterable $iterable = null) {
10 function bar(iterable $iterable = []) {
14 function baz(iterable $iterable = 1) {
20 Deprecated: foo(): Implicitly marking parameter $iterable as nullable is deprecated, the explicit n…
22 Fatal error: Cannot use int as default value for parameter $iterable of type Traversable|array in %…
H A Diterable_001.phpt2 iterable type#001
6 function test(iterable $iterable) {
7 var_dump($iterable);
48 test(): Argument #1 ($iterable) must be of type Traversable|array, int given, called in %s on line …
H A Diterable_alias_redundancy_iterable.phpt2 iterable type with second iterable should be redundant
6 function bar(): iterable|iterable|null {
H A Diterable_003.phpt2 iterable type#003 - Return types
6 function foo(): iterable {
9 function bar(): iterable {
13 function baz(): iterable {
H A Diterable_alias_redundancy_object_variance.phpt2 iterable type with object should be allowed in variance checks
7 public object|iterable $x;
12 public object|iterable $y;
H A Diterable_alias_redundancy_object_1.phpt2 iterable type with object should NOT be redundant 1
6 function bar(): iterable|object|null {
H A Diterable_alias_redundancy_object_2.phpt2 iterable type with object should NOT be redundant 2
6 function bar(): object|iterable|null {
H A Dor_null.phpt2 Test "or null"/"or be null" in type-checking errors for userland functions with iterable
8 function iterableF(?iterable $param) {}
15 function returnIterable(): ?iterable {
25 function returnMissingIterable(): ?iterable {
H A Diterable_alias_redundancy_array_1.phpt2 iterable type with array should be redundant
6 function bar(): array|iterable|null {
H A Diterable_alias_redundancy_array_2.phpt2 iterable type with array should be redundant
6 function bar(): iterable|array|null {
/php-src/ext/reflection/tests/
H A Diterable_Reflection.phpt2 iterable Type in Reflection
6 $function = function(iterable $arg): iterable {};
24 public iterable $iterable;
66 string(8) "iterable"
67 string(8) "iterable"
72 string(8) "iterable"
73 string(8) "iterable"
78 string(8) "iterable"
79 string(8) "iterable"
84 string(8) "iterable"
[all …]
H A DReflectionClass_isIterateable_001.phpt34 echo "Is $class iterable? ";
43 Is Traversable iterable? bool(false)
44 Is Iterator iterable? bool(false)
45 Is IteratorAggregate iterable? bool(false)
46 Is ExtendsIterator iterable? bool(false)
47 Is ExtendsIteratorAggregate iterable? bool(false)
48 Is IteratorImpl iterable? bool(true)
49 Is IteratorAggregateImpl iterable? bool(true)
50 Is ExtendsIteratorImpl iterable? bool(true)
51 Is ExtendsIteratorAggregateImpl iterable? bool(true)
[all …]
/php-src/tests/lang/
H A DforeachLoop.011.phpt2 Changing from an interable type to a non iterable type during the iteration
5 echo "\nChange from array to non iterable:\n";
13 echo "\nChange from object to non iterable:\n";
25 Change from array to non iterable:
30 Change from object to non iterable:
/php-src/Zend/tests/type_declarations/intersection_types/variance/
H A Dvalid8.phpt2 Replacing iterable type with intersection type
9 function method(): iterable {}
10 function method2(): iterable|int {}
11 function method3(): iterable|Z {}
/php-src/Zend/tests/
H A Dbug80391.phpt9 public function method3(iterable $x) {}
10 public function method4(iterable $x) {}
14 public function method1(): iterable {}
15 public function method2(): iterable {}
/php-src/Zend/tests/typehints/
H A Dbug76198.phpt2 "iterable" must not be fully qualified
6 function foo(): \iterable {
13 Fatal error: Type declaration 'iterable' must be unqualified in %s on line %d
/php-src/Zend/tests/type_declarations/
H A Dtyped_properties_076.phpt16 public iterable $iterable;
59 valid($test, 'iterable', 'array', [1, 2, 3]);
62 valid($test, 'iterable', 'Iterator', new ArrayIterator);
63 invalid($test, 'Iterator', 'iterable', [1, 2, 3]);
64 valid($test, 'object', 'iterable', new ArrayIterator);
65 invalid($test, 'iterable', 'object', new stdClass);
/php-src/Zend/tests/type_declarations/dnf_types/variance/
H A Dvalid8.phpt2 Covariant replacement of iterable type with intersection type in DNF type
9 function method1(): iterable|string {}
10 function method2(): iterable|int {}
H A Dvalid9.phpt2 Covariant replacement of iterable type with unregistered intersection type in DNF type
7 function method1(): iterable|string {}
8 function method2(): iterable|int {}
/php-src/Zend/tests/type_declarations/union_types/redundant_types/
H A Diterable_and_Traversable.phpt2 Using both iterable and Traversable
6 function test(): iterable|Traversable {
H A Diterable_and_array.phpt2 Using both iterable and array
6 function test(): iterable|array {
H A Diterable_and_Traversable_2.phpt2 Using both iterable and Traversable, with extra classes
6 function test(): iterable|Traversable|ArrayAccess {
/php-src/Zend/tests/type_declarations/union_types/variance/
H A Dvalid.phpt11 public iterable $prop2;
16 public function method4(Traversable|X $a): iterable|X {}
25 public function method4(iterable|X $a): Traversable|X {}
/php-src/Zend/tests/type_declarations/intersection_types/invalid_types/
H A Dinvalid_iterable_type.phpt2 iterable type cannot take part in an intersection type
6 function foo(): iterable&Iterator {}

Completed in 25 milliseconds

123