|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #76198 Wording: "iterable" is not a scalar type
Submitted: 2018-04-08 18:11 UTC Modified: -
From: Assigned:
Status: Closed Package: *General Issues
PHP Version: 7.2.4 OS:
Private report: No CVE-ID: None
 [2018-04-08 18:11 UTC]
The wording suggests that `iterable` is a scalar type when it definitely is not as neither `array` nor `Traversable` are scalar types.

Test script:
<?php function f(): \iterable {} ?>

Expected result:
Fatal error: Type declaration 'iterable' must be unqualified in %s on line %d

Actual result:
Fatal error: Scalar type declaration 'iterable' must be unqualified in %s on line %d


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2018-04-14 11:09 UTC]
Automatic comment on behalf of levim
Log: Fix bug #76198
 [2018-04-14 11:09 UTC]
-Status: Open +Status: Closed
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Apr 16 08:01:32 2024 UTC