From: Al Viro <viro@ZenIV.linux.org.uk>
To: Pushkar Jambhlekar <pushkar.iit@gmail.com>
Cc: Joe Perches <joe@perches.com>,
linux-fsdevel@vger.kernel.org,
linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] FS: Fixing return type of unsigned_offsets
Date: Thu, 11 May 2017 07:07:44 +0100 [thread overview]
Message-ID: <20170511060744.GJ390@ZenIV.linux.org.uk> (raw)
In-Reply-To: <CAMvNc9AKzs82zaHq1z+gAfsSu90PS_9N+L3VDEMdYDK0PbhA2A@mail.gmail.com>
On Thu, May 11, 2017 at 10:34:02AM +0530, Pushkar Jambhlekar wrote:
> If I remove '!!', sparse flags warning:
>
> fs/read_write.c:38:29: warning: incorrect type in return expression
> (different base types)
> fs/read_write.c:38:29: expected bool
> fs/read_write.c:38:29: got restricted fmode_t
>
> It means explicit conversion is needed.
FVO"needed" equal to "needed to make sparse STFU"? If anything, that's
sparse being wrong - evaluate.c:check_assignment_type() should do
if (t == &ctype_bool) {
if (is_fouled_type(s))
warning((*rp)->pos, "%s degrades to integer",
show_typename(s->ctype.base_type));
goto Cast;
}
right after
} else if (!(sclass & TYPE_RESTRICT))
goto Cast;
next prev parent reply other threads:[~2017-05-11 6:07 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-11 4:27 [PATCH] FS: Fixing return type of unsigned_offsets Pushkar Jambhlekar
2017-05-11 4:39 ` Joe Perches
2017-05-11 4:43 ` Pushkar Jambhlekar
2017-05-11 4:55 ` Joe Perches
2017-05-11 4:55 ` Joe Perches
2017-05-11 5:04 ` Pushkar Jambhlekar
2017-05-11 6:07 ` Al Viro [this message]
2017-05-11 16:21 ` [PATCH] avoid useless warning for 'bool <- restricted type' conversion Luc Van Oostenryck
2017-05-11 19:41 ` Christopher Li
2017-05-11 19:48 ` Luc Van Oostenryck
2017-05-11 20:20 ` Luc Van Oostenryck
2017-05-11 20:09 ` [PATCH] FS: Fixing return type of unsigned_offsets Luc Van Oostenryck
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=20170511060744.GJ390@ZenIV.linux.org.uk \
--to=viro@zeniv.linux.org.uk \
--cc=joe@perches.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pushkar.iit@gmail.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.