Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 3.7.1

Bug #19879 bitwise and operator '&' interpreted as reference by value
Submitted: 2013-04-02 22:24 UTC
From: dennisu Assigned: squiz
Status: Closed Package: PHP_CodeSniffer (version 1.4.4)
PHP Version: 5.4.13 OS: Linux Debian 6
Roadmaps: (Not assigned)    
Comments Add Comment Add patch

Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem : 12 + 26 = ?

 [2013-04-02 22:24 UTC] dennisu (Dennis Ungelbach)
Description: ------------ The bitwise and operator '&' in the code below is interpreted as reference by value although there is a space between the operator and the variable $p. array( 'umask' => sprintf("%04o", @umask()), 'human' => $str, 'octal' => sprintf("0%o", 0777 & $p), 'decimal' => sprintf("%04o", $p) ), Expected result: ---------------- no error should be reported by cs Actual result: -------------- NotAllowed, Priorit├Ąt: Hoch Call-time pass-by-reference calls are prohibited No description available. Please upgrade to latest checkstyle version.


 [2013-04-03 03:36 UTC] squiz (Greg Sherwood)
-Status: Open +Status: Closed -Assigned To: +Assigned To: squiz
Fix committed to github repo: 2f9b993a3db058