Re: Planning an RFC to allow calls to global functions in constant expressions

From: Date: Sat, 01 Feb 2020 23:50:49 +0000
Subject: Re: Planning an RFC to allow calls to global functions in constant expressions
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-108344@lists.php.net to get a copy of this message
Hi! > For example, allow \count(), > \strlen(), \array_merge(), and > \in_array(), > but don't allow functions such as > \strtolower() (different in Turkish locale), What happens if a function like strlen() is applied to a non-string argument? Conversion to string is certainly runtime-dependent even for primitive types like floats. > allow calls to all global functions Not sure I understand here - when these calls will be happening? And if you need a value that depends on runtime calculation, what's wrong with using define()? -- Stas Malyshev smalyshev@gmail.com

« previous php.internals (#108344) next »