|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2015-01-08 23:55 UTC] ajf@php.net
-Status: Open
+Status: Not a bug
-Package: Feature/Change Request
+Package: *General Issues
[2015-01-08 23:55 UTC] ajf@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Nov 22 04:00:01 2025 UTC |
Description: ------------ func_get_args, func_num_args, func_get_arg functions executed inside assert('') work on assert's arguments, and not on arguments of function assert is in. Because assert transparently handles variables scope, one could expect that it works transparently on arguments as well. With all PHP functions accepting variable number of arguments and only basic type hints, such assertions are quite important. Reproduce code: --------------- function test() { assert('func_num_args()==2'); } test('one','two'); Expected result: ---------------- nothing Actual result: -------------- assertion fails