php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #74352 Summary
Submitted: 2017-03-31 20:20 UTC Modified: 2017-03-31 20:48 UTC
Votes:2
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: deadmoras5 at gmail dot com Assigned:
Status: Not a bug Package: *Programming Data Structures
PHP Version: 7.1Git-2017-03-31 (Git) OS: Windows 8.1 x64
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: deadmoras5 at gmail dot com
New email:
PHP Version: OS:

 

 [2017-03-31 20:20 UTC] deadmoras5 at gmail dot com
Description:
------------
Mixed (type) it's not a mixed in other language (java, c, etc);
It's a unique type, because  string, array, any class and other not = mixed or \mixed;


Test script:
---------------
public function changeValue(string $name, \mixed $data): ClassName {}

$object = new ClassName();
$object->changeValue('name', 'email')->getResult();


Expected result:
----------------
FatalThrowableError in ClassName.php line 54:
Type error: Argument 2 passed to App\Http\ResponseDataService\ClassName::changeValue() must be an instance of mixed, string given


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2017-03-31 20:48 UTC] requinix@php.net
-Status: Open +Status: Not a bug
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri May 10 04:01:31 2024 UTC