From: Peter Maydell <peter.maydell@linaro.org>
To: "Michael S. Tsirkin" <mst@redhat.com>
Cc: "Paolo Bonzini" <pbonzini@redhat.com>,
"Richard Henderson" <richard.henderson@linaro.org>,
"Philippe Mathieu-Daudé" <philmd@redhat.com>,
"QEMU Developers" <qemu-devel@nongnu.org>,
"Stefan Hajnoczi" <stefanha@redhat.com>
Subject: Re: [PATCH] checkpatch: reversed logic with acpi test checks
Date: Thu, 4 Jun 2020 20:52:45 +0100 [thread overview]
Message-ID: <CAFEAcA8r31UiQ-a=DfDNrw=Fex-m8X6ezF7XJsRFyPg4eVV=cw@mail.gmail.com> (raw)
In-Reply-To: <20200604150734-mutt-send-email-mst@kernel.org>
On Thu, 4 Jun 2020 at 20:09, Michael S. Tsirkin <mst@redhat.com> wrote:
> On Thu, Jun 04, 2020 at 08:45:15PM +0200, Paolo Bonzini wrote:
> > On 02/06/20 07:36, Michael S. Tsirkin wrote:
> > > + } elsif (not $name =~ m#^tests/qtest/bios-tables-test-allowed-diff.h$#) {
> > > $$acpi_nontestexpected = $name;
> > > }
> > > if (defined $$acpi_testexpected and defined $$acpi_nontestexpected) {
> > >
> >
> > Queued with "!~" to achieve the logical not.
> >
> > Paolo
>
> Hmm perl manual says "not" is the logical not. Weird.
> What's !~? My perl is a bit rusty :)
man perlop says:
# Binary "!~" is just like "=~" except the return value is negated in
the logical sense.
So it's more idiomatic to use it directly rather than using =~ and then
doing a logical negation separately.
thanks
-- PMM
prev parent reply other threads:[~2020-06-04 19:54 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-02 5:36 [PATCH] checkpatch: reversed logic with acpi test checks Michael S. Tsirkin
2020-06-02 7:40 ` Philippe Mathieu-Daudé
2020-06-02 11:39 ` Auger Eric
2020-06-04 18:45 ` Paolo Bonzini
2020-06-04 19:08 ` Michael S. Tsirkin
2020-06-04 19:52 ` Peter Maydell [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAFEAcA8r31UiQ-a=DfDNrw=Fex-m8X6ezF7XJsRFyPg4eVV=cw@mail.gmail.com' \
--to=peter.maydell@linaro.org \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=philmd@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=richard.henderson@linaro.org \
--cc=stefanha@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.