All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andy Whitcroft <apw@canonical.com>
To: Hitoshi Mitake <mitake@dcl.info.waseda.ac.jp>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH][RFC] Removing wrong judgement of checkpatch.pl for return as function
Date: Fri, 6 Nov 2009 22:28:28 +0000	[thread overview]
Message-ID: <20091106222828.GC5191@penfold> (raw)
In-Reply-To: <20091103.104932.625281420231629894.mitake@dcl.info.waseda.ac.jp>

On Tue, Nov 03, 2009 at 10:49:32AM +0900, Hitoshi Mitake wrote:
> 
> Hi,
> 
> I found a strange behaviour of checkpatch.pl.
> 
> The C statement:
> 	return (type)value;
> is regarded as return like a function form by checkpatch.pl.
> So checkpatch.pl causes "Return is not a function." error
> when processing statements like this.
> 
> I think statements like above are innocence. These are only doing type cast.
> This patch removes the behaviour of checkpatch.pl.
> 
> But I don't have confidence about coding style of Linux kernel.
> Is my thought correct? Or the behaviour of current checkpatch.pl is correct?
> Request for comment.

Do you have a patch example which triggers this?  If I test the current
version with this specific fragment I do not get a report.  This one
collapses to '1value' which means it shouldn't trigger the report.

If you do have a specific patch which triggered this could you email it
over, also could you confirm the version of checkpatch which shows this
with checkpatch -v.

Thanks.

-apw

  reply	other threads:[~2009-11-06 22:28 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-03  1:49 [PATCH][RFC] Removing wrong judgement of checkpatch.pl for return as function Hitoshi Mitake
2009-11-06 22:28 ` Andy Whitcroft [this message]
2009-11-07  1:14   ` Hitoshi Mitake
2009-11-12 12:49     ` Andy Whitcroft
2009-11-12 12:58       ` Hitoshi Mitake

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=20091106222828.GC5191@penfold \
    --to=apw@canonical.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mitake@dcl.info.waseda.ac.jp \
    /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.