Linux SPARSE checker discussions
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: linux-sparse@vger.kernel.org
Cc: KOSAKI Motohiro <kosaki.motohiro@gmail.com>
Subject: [PATCH 2/2] sparse: Add 'error' to ignored attributes
Date: Mon, 18 Jun 2012 14:07:49 +0300	[thread overview]
Message-ID: <20120618110749.GB19915@elgon.mountain> (raw)
In-Reply-To: <cover.1340005296.git.dan.carpenter@oracle.com>

From: KOSAKI Motohiro <kosaki.motohiro@gmail.com>

Add some more ignored attributes which are used in glibc header files.  It
silences the warnings such as the following:

/usr/include/bits/fcntl2.h:36:1: error: attribute '__error__': unknown attribute

Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@gmail.com>
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
 ident-list.h |    1 +
 parse.c      |    2 ++
 2 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/ident-list.h b/ident-list.h
index 973bf57..a0b808f 100644
--- a/ident-list.h
+++ b/ident-list.h
@@ -89,6 +89,7 @@ IDENT(dllexport); IDENT(__dllexport__);
 IDENT(restrict); IDENT(__restrict);
 IDENT(artificial); IDENT(__artificial__);
 IDENT(vector_size); IDENT(__vector_size__);
+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 2dcd488..db6b519 100644
--- a/parse.c
+++ b/parse.c
@@ -509,6 +509,8 @@ const char *ignored_attributes[] = {
 	"__dllexport__",
 	"dllimport",
 	"__dllimport__",
+	"error",
+	"__error__",
 	"externally_visible",
 	"__externally_visible__",
 	"fastcall",
-- 
1.7.8.rc0.dirty

  parent reply	other threads:[~2012-06-18 11:07 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-18 11:06 [PATCH 0/2] Add some more ignored attributes for glibc Dan Carpenter
2012-06-18 11:07 ` [PATCH 1/2] sparse: Add '__vector_size__' to ignored attributes Dan Carpenter
2012-06-25  9:44   ` Christopher Li
2012-06-18 11:07 ` Dan Carpenter [this message]
2012-06-25  9:47   ` [PATCH 2/2] sparse: Add 'error' " Christopher Li

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=20120618110749.GB19915@elgon.mountain \
    --to=dan.carpenter@oracle.com \
    --cc=kosaki.motohiro@gmail.com \
    --cc=linux-sparse@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox