diff options
author | Joe Perches <joe@perches.com> | 2016-01-20 23:59:15 +0100 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-01-21 02:09:18 +0100 |
commit | 938224b5e596c1c30d968ffd927a578ea7c4f45b (patch) | |
tree | 8d2ae9d42c9bc887f0dc984979d2e7c01ecf990d /crypto/lrw.c | |
parent | lib/clz_tab.c: put in lib-y rather than obj-y (diff) | |
download | linux-938224b5e596c1c30d968ffd927a578ea7c4f45b.tar.xz linux-938224b5e596c1c30d968ffd927a578ea7c4f45b.zip |
checkpatch: warn when casting constants to c90 int or longer types
Linus Torvalds wrote:
> I can't but help to react that this:
> #define IOMMU_ERROR_CODE (~(unsigned long) 0)
> Not that this *matters*, but it's a bit odd to have to cast constants
> to perfectly regular C types.
So add a test that looks for constants that are cast to
standard C90 int or longer types and suggest using C90
"6.4.4.1 Integer constants" integer-suffixes instead.
Miscellanea:
o Add a --fix option too
Signed-off-by: Joe Perches <joe@perches.com>
Suggested-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'crypto/lrw.c')
0 files changed, 0 insertions, 0 deletions