|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2004-04-21 16:41 UTC] amt@php.net
[2004-08-03 11:07 UTC] suky0001 at hotmail dot com
[2004-08-03 11:17 UTC] derick@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Dec 06 18:00:01 2025 UTC |
Description: ------------ When using class type hints with a string a runtime error occurs. Reproduce code: --------------- <?php function foo(string $bar){ echo $bar; } foo("baz"); ?> Expected result: ---------------- The printout of "baz" Actual result: -------------- Fatal error: Argument 1 must be an object of class string in c:\program files\apache group\Apache\htdocs\index.php on line 2