"Fossies" - the Fresh Open Source Software Archive

Member "php-7.4.1/Zend/tests/return_types/001.phpt" (17 Dec 2019, 283 Bytes) of package /linux/www/php-7.4.1.tar.xz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 --TEST--
    2 Returned nothing, expected array
    3 --FILE--
    4 <?php
    5 function test1() : array {
    6 }
    7 
    8 test1();
    9 --EXPECTF--
   10 Fatal error: Uncaught TypeError: Return value of test1() must be of the type array, none returned in %s:%d
   11 Stack trace:
   12 #0 %s(%d): test1()
   13 #1 {main}
   14   thrown in %s on line %d