Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

Pure Intersection Types - PHP 8.1

function count_and_iterate(Iterator&Countable $value) {
    foreach ($value as $val) {
        echo $val;
    }

    count($value);
}
Source by www.php.net #
 
PREVIOUS NEXT
Tagged: #Pure #Intersection #Types #PHP
ADD COMMENT
Topic
Name
3+7 =