File sparse-0.4.4-add_error_to_ignore.patch of Package sparse

commit 0a04210cc856267d8371592dc55f8b8bb7596ecc
Author:     KOSAKI Motohiro <kosaki.motohiro@gmail.com>
AuthorDate: Mon Jun 25 02:47:20 2012 -0700
Commit:     Christopher Li <sparse@chrisli.org>
CommitDate: Mon Jun 25 02:47:20 2012 -0700

    sparse: Add 'error' to ignored attributes
    
    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>
    Signed-off-by: Christopher Li <sparse@chrisli.org>
---
 ident-list.h | 1 +
 parse.c      | 2 ++
 2 files changed, 3 insertions(+)

diff --git a/ident-list.h b/ident-list.h
index 5bdfa90..e00cd96 100644
--- a/ident-list.h
+++ b/ident-list.h
@@ -90,6 +90,7 @@ IDENT(restrict); IDENT(__restrict);
 IDENT(artificial); IDENT(__artificial__);
 IDENT(leaf); IDENT(__leaf__);
 IDENT(vector_size); IDENT(__vector_size__);
+IDENT(error); IDENT(__error__);
 
 
 /* Preprocessor idents.  Direct use of __IDENT avoids mentioning the keyword
diff --git a/parse.c b/parse.c
index 44eae3d..99f2ba8 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",
openSUSE Build Service is sponsored by