|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2008-05-15 18:42 UTC] mjijackson at gmail dot com
[2008-05-15 21:50 UTC] felipe@php.net
[2008-05-15 22:58 UTC] mjijackson at gmail dot com
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 23:00:01 2025 UTC |
Description: ------------ parse_ini_file() correctly uses the | and & bitwise operators on constants. However, it does not correctly interpret the ^ (XOR) operator. Instead, it interprets the entire statement as a string. Reproduce code: --------------- *** test.ini *** or = E_ERROR | E_PARSE xor = E_ALL ^ E_NOTICE *** PHP *** $ini = parse_ini_file('test.ini'); echo $ini['or'] . ' ' . (E_ERROR | E_PARSE); echo "\n"; echo $ini['xor'] . ' ' . (E_ALL ^ E_NOTICE); Expected result: ---------------- 5 5 6135 6135 Actual result: -------------- 5 5 E_ALL ^ E_NOTICE 6135