- Subject: tiny patch for userland project
- From: KOSAKI Motohiro <kosaki.motohiro@xxxxxxxxx>
- Date: Thu, 14 Jun 2012 00:53:52 -0400
- Cc: kosaki.motohiro@xxxxxxxxx
- User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:12.0) Gecko/20120428 Thunderbird/12.0.1
Hi,
Today, I tried to use 'smatch' for ruby project and I found plenty false positive errors.
They were mainly caused that glibc uses some no smatch recognized attributes. I did apply
following patch myself. (see below)
Is there any more good way? I didn't find a hint from README.
And, I have one unsolved issue. I've seen following annoying error a lot.
/usr/include/bits/xopen_lim.h:122:6: warning: constant 9223372036854775807L is so big it is long long
Because of, /usr/include/limits.h has "#define LONG_MAX 9223372036854775807L" and it is completely
valid on 64bit OS. Is there any way to disable this message when using 64bit?
Thanks.
diff --git a/ident-list.h b/ident-list.h
index b94aece..17fa480 100644
--- a/ident-list.h
+++ b/ident-list.h
@@ -87,6 +87,8 @@ IDENT(fastcall); IDENT(__fastcall__);
IDENT(dllimport); IDENT(__dllimport__);
IDENT(dllexport); IDENT(__dllexport__);
IDENT(restrict); IDENT(__restrict);
+IDENT(artificial); IDENT(__artificial__);
+IDENT(error); IDENT(__error__);
/* Preprocessor idents. Direct use of __IDENT avoids mentioning the keyword
* itself by name, preventing these tokens from expanding when compiling
diff --git a/parse.c b/parse.c
index ca497d6..adec91d 100644
--- a/parse.c
+++ b/parse.c
@@ -571,6 +571,10 @@ const char *ignored_attributes[] = {
"__warning__",
"weak",
"__weak__",
+ "artificial",
+ "__artificial__",
+ "error",
+ "__error__",
};
--
To unsubscribe from this list: send the line "unsubscribe smatch" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
[Linux USB Devel]
[Video for Linux]
[Linux Audio Users]
[Photo]
[Yosemite News]
[Yosemite Photos]
[Video Projectors]
[PDAs]
[Free Online Dating]
[Hacking TiVo]
[Linux Kernel]
[Linux SCSI]
[XFree86]
[Devices]
[Big List of Linux Books]