Are there any plans to allow bitwise declaration of flags?
Example:
class foo {
const FLAG_1 = 1;
const FLAG_2 = 2;
const FLAG_3 = 4;
private $Flags = self::FLAG_1 | self::FLAG_3
}
The above doesn't work, gets a syntax error on the | operator.
Has anyone thought about a change to allow this type of functionality?
I end up doing something like this which is less than optimal
private $Flags = 3 /* self::FLAG_1 | self::FLAG_3 */
Thanks,
-Clint
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php