qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Re: [PATCH v2 3/3] checkpatch: adjust to QEMUisms


From: Blue Swirl
Subject: [Qemu-devel] Re: [PATCH v2 3/3] checkpatch: adjust to QEMUisms
Date: Mon, 17 Jan 2011 19:37:16 +0000

On Mon, Jan 17, 2011 at 7:40 AM, Paolo Bonzini <address@hidden> wrote:
> On 01/15/2011 06:45 PM, Blue Swirl wrote:
>>
>> +                       if ($level == 0 && !$block =~ /^\s*\{/ &&
>> !$allowed) {
>
> I'm not a Perl expert at all, but I think you need parentheses for the
> argument of "!":

! has higher precedence than =~:
http://perldoc.perl.org/perlop.html#Operator-Precedence-and-Associativity

>  if ($level == 0 && !($block =~ /^\s*\{/) && !$allowed) {

Maybe instead:
if ($level == 0 && $block !~ /^\s*\{/ && !$allowed) {



reply via email to

[Prev in Thread] Current Thread [Next in Thread]