|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #80352 Behaviour of array_intersect and array_intersect_key changed
Submitted: 2020-11-12 13:15 UTC Modified: 2020-11-12 13:18 UTC
From: jelly dot legend at gmail dot com Assigned:
Status: Not a bug Package: Arrays related
PHP Version: 8.0.0RC4 OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: jelly dot legend at gmail dot com
New email:
PHP Version: OS:


 [2020-11-12 13:15 UTC] jelly dot legend at gmail dot com
PHP 8.0.0a promoted the warning if passing invalid number of arrays to array_intersect(_key) was promoted to a fatal error. However, it seem that something changed in the version 8.0.0b4 since no error is produced.

Test script:

$arrayArray = [

array_intersect_key(...$arrayArray);// array_intersect

$arrayArray = [

array_intersect_key(...$arrayArray);// array_intersect


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2020-11-12 13:18 UTC]
-Status: Open +Status: Not a bug
PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Sat Jun 10 05:03:36 2023 UTC