Function boolval()

From: Date: Fri, 27 Apr 2012 20:14:53 +0000
Subject: Function boolval()
Groups: php.internals 
Request: Send a blank email to internals+get-60337@lists.php.net to get a copy of this message
Hi, I suggest we add a function boolval(). It simply converts the given argument to a boolean, like strval(), intval() and floatval(). I already have an implementation ready[1]. Why? * It is missing in the current list of *val()-functions and people expect it to exist. I'd say it is an inconsistency. * It can be used as a callback, which is why a bool-cast does not suffice. -- Jille [1] https://github.com/php/php-src/pull/60

« previous php.internals (#60337) next »