All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] Minor enhancements and fixes
@ 2015-07-30  0:26 Tony Camuso
  2015-07-30  0:26 ` [PATCH 1/3] .gitignore: add cscope and Qt project files Tony Camuso
                   ` (4 more replies)
  0 siblings, 5 replies; 36+ messages in thread
From: Tony Camuso @ 2015-07-30  0:26 UTC (permalink / raw)
  To: sparse, linux-sparse; +Cc: tcamuso

[PATCH 1/3] .gitignore: add cscope and Qt project files
Useful if you're using cscope and Qt as an IDE

[PATCH 2/3] c2xml.c, parse.c: gcc 5+ stricter case statement parsing
The gcc 5.1.1 compiler complains if any of the possible values for the
switch variable are not covered by the case statement. Basically, it
forces the employment of the default case.

[PATCH 3/3] Add NOWARN and NOERR compile conditions
Provides compile conditionals to buid sparse without reporting
warnings and errors. This isn't quite reducing it to a tokenizer, but
it has the same effect for our application. Reports from the semantic
parser and the time they take are undesirable in our application.

 .gitignore |  7 +++++++
 c2xml.c    |  2 +-
 lib.c      | 21 +++++++++++++++++++++
 parse.c    | 13 +++++++++++++
 4 files changed, 42 insertions(+), 1 deletion(-)

^ permalink raw reply	[flat|nested] 36+ messages in thread

* [PATCH 1/3] .gitignore: add cscope and Qt project files
  2015-07-30  0:26 [PATCH 0/3] Minor enhancements and fixes Tony Camuso
@ 2015-07-30  0:26 ` Tony Camuso
  2015-08-03 17:41   ` [PATCH 1/3 v2] " Tony Camuso
  2015-08-10 12:33   ` [PATCH 1/3 v3] " Tony Camuso
  2015-07-30  0:26 ` [PATCH 2/3] c2xml.c, parse.c: gcc 5+ stricter case statement parsing Tony Camuso
                   ` (3 subsequent siblings)
  4 siblings, 2 replies; 36+ messages in thread
From: Tony Camuso @ 2015-07-30  0:26 UTC (permalink / raw)
  To: sparse, linux-sparse; +Cc: tcamuso

Signed-off-by: Tony Camuso <tcamuso@redhat.com>
---
 .gitignore | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/.gitignore b/.gitignore
index d32d063..e1734a9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -9,6 +9,7 @@
 pre-process.h
 sparse.pc
 version.h
+cscope*
 
 # programs
 test-inspect
@@ -40,3 +41,9 @@ series
 # local makefile
 local.mk
 
+# files related to Qt
+*.pro*
+*.pri*
+*.qt
+*.sparse
+*.save
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [PATCH 2/3] c2xml.c, parse.c: gcc 5+ stricter case statement parsing
  2015-07-30  0:26 [PATCH 0/3] Minor enhancements and fixes Tony Camuso
  2015-07-30  0:26 ` [PATCH 1/3] .gitignore: add cscope and Qt project files Tony Camuso
@ 2015-07-30  0:26 ` Tony Camuso
  2015-08-04 12:06   ` [PATCH 2/3 v2] Handle all enum members in case statements Tony Camuso
  2015-08-10 12:35   ` [PATCH 2/3 v3] Add default case to switches on enum variables Tony Camuso
  2015-07-30  0:26 ` [PATCH 3/3] Add NOWARN and NOERR compile conditions Tony Camuso
                   ` (2 subsequent siblings)
  4 siblings, 2 replies; 36+ messages in thread
From: Tony Camuso @ 2015-07-30  0:26 UTC (permalink / raw)
  To: sparse, linux-sparse; +Cc: tcamuso

The gcc 5+ compiler complains if case statements do not use all the
possible values of the switch variable. Just forces the coder to use
"default" in their case statements.

Signed-off-by: Tony Camuso <tcamuso@redhat.com>
---
 c2xml.c | 2 +-
 parse.c | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/c2xml.c b/c2xml.c
index 67486c7..96657d5 100644
--- a/c2xml.c
+++ b/c2xml.c
@@ -214,6 +214,7 @@ static void examine_symbol(struct symbol *sym, xmlNodePtr node)
 	case SYM_UNINITIALIZED:
 		newProp(child, "base-type-builtin", builtin_typename(sym));
 		break;
+	default: break;
 	}
 	return;
 }
@@ -330,4 +331,3 @@ int main(int argc, char **argv)
 
 	return 0;
 }

^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-07-30  0:26 [PATCH 0/3] Minor enhancements and fixes Tony Camuso
  2015-07-30  0:26 ` [PATCH 1/3] .gitignore: add cscope and Qt project files Tony Camuso
  2015-07-30  0:26 ` [PATCH 2/3] c2xml.c, parse.c: gcc 5+ stricter case statement parsing Tony Camuso
@ 2015-07-30  0:26 ` Tony Camuso
  2015-07-30  2:55   ` Josh Triplett
                     ` (3 more replies)
  2015-08-03 18:10 ` [PATCH 0/3] Minor enhancements and fixes Tony Camuso
  2015-12-02 18:52 ` Tony Camuso
  4 siblings, 4 replies; 36+ messages in thread
From: Tony Camuso @ 2015-07-30  0:26 UTC (permalink / raw)
  To: sparse, linux-sparse; +Cc: tcamuso

Allows building sparse to avert reporting semantic problems, e.g.
using sparse as a tokenizer to create a graph of KABI symbols and
their dependencies.

Signed-off-by: Tony Camuso <tcamuso@redhat.com>
---
 lib.c   | 21 +++++++++++++++++++++
 parse.c | 12 ++++++++++++
 2 files changed, 33 insertions(+)

diff --git a/lib.c b/lib.c
index 8dc5bcf..cb10bce 100644
--- a/lib.c
+++ b/lib.c
@@ -48,6 +48,13 @@
 int verbose, optimize, optimize_size, preprocessing;
 int die_if_error = 0;
 
+#ifdef NOWARN
+#pragma message "Built with NOWARN"
+#endif
+#ifdef NOERR
+#pragma message "Built with NOERR"
+#endif
+
 #ifndef __GNUC__
 # define __GNUC__ 2
 # define __GNUC_MINOR__ 95
@@ -103,6 +110,9 @@ unsigned int hexval(unsigned int c)
 
 static void do_warn(const char *type, struct position pos, const char * fmt, va_list args)
 {
+#ifdef NOWARN
+	return;
+#else
 	static char buffer[512];
 	const char *name;
 
@@ -111,9 +121,12 @@ static void do_warn(const char *type, struct position pos, const char * fmt, va_
 		
 	fprintf(stderr, "%s:%d:%d: %s%s\n",
 		name, pos.line, pos.pos, type, buffer);
+#endif
 }
 
+#ifndef NOWARN
 static int max_warnings = 100;
+#endif
 static int show_info = 1;
 
 void info(struct position pos, const char * fmt, ...)
@@ -129,6 +142,9 @@ void info(struct position pos, const char * fmt, ...)
 
 static void do_error(struct position pos, const char * fmt, va_list args)
 {
+#ifdef NOERR
+	return;
+#else
 	static int errors = 0;
         die_if_error = 1;
 	show_info = 1;
@@ -145,10 +161,14 @@ static void do_error(struct position pos, const char * fmt, va_list args)
 
 	do_warn("error: ", pos, fmt, args);
 	errors++;
+#endif
 }	
 
 void warning(struct position pos, const char * fmt, ...)
 {
+#ifdef NOWARN
+	return;
+#else
 	va_list args;
 
 	if (Wsparse_error) {
@@ -171,6 +191,7 @@ void warning(struct position pos, const char * fmt, ...)
 	va_start(args, fmt);
 	do_warn("warning: ", pos, fmt, args);
 	va_end(args);
+#endif
 }
 
 void sparse_error(struct position pos, const char * fmt, ...)
diff --git a/parse.c b/parse.c
index 02275d8..f773fe8 100644
--- a/parse.c
+++ b/parse.c
@@ -44,6 +44,13 @@
 #include "expression.h"
 #include "target.h"
 
+#ifdef NOWARN
+#pragma message "Built with NOWARN"
+#endif
+#ifdef NOERR
+#pragma message "Built with NOERR"
+#endif
+
 static struct symbol_list **function_symbol_list;
 struct symbol_list *function_computed_target_list;
 struct statement_list *function_computed_goto_list;
@@ -2746,8 +2753,13 @@ struct token *external_declaration(struct token *token, struct symbol_list **lis
 
 	/* Just a type declaration? */
 	if (!ident) {
+
+#if defined NOWARN || defined NOERR
+		return token->next;
+#else
 		warning(token->pos, "missing identifier in declaration");
 		return expect(token, ';', "at the end of type declaration");
+#endif
 	}
 
 	/* type define declaration? */
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-07-30  0:26 ` [PATCH 3/3] Add NOWARN and NOERR compile conditions Tony Camuso
@ 2015-07-30  2:55   ` Josh Triplett
  2015-07-30 11:45     ` Tony Camuso
  2015-07-31 17:07     ` Tony Camuso
  2015-07-31 17:12   ` [PATCH 3/3 V2] lib.c: add Wall_off switch Tony Camuso
                     ` (2 subsequent siblings)
  3 siblings, 2 replies; 36+ messages in thread
From: Josh Triplett @ 2015-07-30  2:55 UTC (permalink / raw)
  To: Tony Camuso; +Cc: sparse, linux-sparse

On Wed, Jul 29, 2015 at 08:26:41PM -0400, Tony Camuso wrote:
> Allows building sparse to avert reporting semantic problems, e.g.
> using sparse as a tokenizer to create a graph of KABI symbols and
> their dependencies.
> 
> Signed-off-by: Tony Camuso <tcamuso@redhat.com>

This doesn't seem like something that should be determined at compile
time.  Ideally, this should be determined at runtime.

>  lib.c   | 21 +++++++++++++++++++++
>  parse.c | 12 ++++++++++++
>  2 files changed, 33 insertions(+)
> 
> diff --git a/lib.c b/lib.c
> index 8dc5bcf..cb10bce 100644
> --- a/lib.c
> +++ b/lib.c
> @@ -48,6 +48,13 @@
>  int verbose, optimize, optimize_size, preprocessing;
>  int die_if_error = 0;
>  
> +#ifdef NOWARN
> +#pragma message "Built with NOWARN"
> +#endif
> +#ifdef NOERR
> +#pragma message "Built with NOERR"
> +#endif
> +
>  #ifndef __GNUC__
>  # define __GNUC__ 2
>  # define __GNUC_MINOR__ 95
> @@ -103,6 +110,9 @@ unsigned int hexval(unsigned int c)
>  
>  static void do_warn(const char *type, struct position pos, const char * fmt, va_list args)
>  {
> +#ifdef NOWARN
> +	return;
> +#else
>  	static char buffer[512];
>  	const char *name;
>  
> @@ -111,9 +121,12 @@ static void do_warn(const char *type, struct position pos, const char * fmt, va_
>  		
>  	fprintf(stderr, "%s:%d:%d: %s%s\n",
>  		name, pos.line, pos.pos, type, buffer);
> +#endif
>  }
>  
> +#ifndef NOWARN
>  static int max_warnings = 100;
> +#endif
>  static int show_info = 1;
>  
>  void info(struct position pos, const char * fmt, ...)
> @@ -129,6 +142,9 @@ void info(struct position pos, const char * fmt, ...)
>  
>  static void do_error(struct position pos, const char * fmt, va_list args)
>  {
> +#ifdef NOERR
> +	return;
> +#else
>  	static int errors = 0;
>          die_if_error = 1;
>  	show_info = 1;
> @@ -145,10 +161,14 @@ static void do_error(struct position pos, const char * fmt, va_list args)
>  
>  	do_warn("error: ", pos, fmt, args);
>  	errors++;
> +#endif
>  }	
>  
>  void warning(struct position pos, const char * fmt, ...)
>  {
> +#ifdef NOWARN
> +	return;
> +#else
>  	va_list args;
>  
>  	if (Wsparse_error) {
> @@ -171,6 +191,7 @@ void warning(struct position pos, const char * fmt, ...)
>  	va_start(args, fmt);
>  	do_warn("warning: ", pos, fmt, args);
>  	va_end(args);
> +#endif
>  }
>  
>  void sparse_error(struct position pos, const char * fmt, ...)
> diff --git a/parse.c b/parse.c
> index 02275d8..f773fe8 100644
> --- a/parse.c
> +++ b/parse.c
> @@ -44,6 +44,13 @@
>  #include "expression.h"
>  #include "target.h"
>  
> +#ifdef NOWARN
> +#pragma message "Built with NOWARN"
> +#endif
> +#ifdef NOERR
> +#pragma message "Built with NOERR"
> +#endif
> +
>  static struct symbol_list **function_symbol_list;
>  struct symbol_list *function_computed_target_list;
>  struct statement_list *function_computed_goto_list;
> @@ -2746,8 +2753,13 @@ struct token *external_declaration(struct token *token, struct symbol_list **lis
>  
>  	/* Just a type declaration? */
>  	if (!ident) {
> +
> +#if defined NOWARN || defined NOERR
> +		return token->next;
> +#else
>  		warning(token->pos, "missing identifier in declaration");
>  		return expect(token, ';', "at the end of type declaration");
> +#endif
>  	}
>  
>  	/* type define declaration? */
> -- 
> 2.4.3
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sparse" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-07-30  2:55   ` Josh Triplett
@ 2015-07-30 11:45     ` Tony Camuso
  2015-07-31 23:46       ` Christopher Li
  2015-07-31 17:07     ` Tony Camuso
  1 sibling, 1 reply; 36+ messages in thread
From: Tony Camuso @ 2015-07-30 11:45 UTC (permalink / raw)
  To: Josh Triplett; +Cc: sparse, linux-sparse

On 07/29/2015 10:55 PM, Josh Triplett wrote:
> On Wed, Jul 29, 2015 at 08:26:41PM -0400, Tony Camuso wrote:
>> Allows building sparse to avert reporting semantic problems, e.g.
>> using sparse as a tokenizer to create a graph of KABI symbols and
>> their dependencies.
>>
>> Signed-off-by: Tony Camuso <tcamuso@redhat.com>
>
> This doesn't seem like something that should be determined at compile
> time.  Ideally, this should be determined at runtime.

I thought it would be less intrusive, since I don't know how useful
this would be to others.

If you prefer a switch, I will do that.


^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-07-30  2:55   ` Josh Triplett
  2015-07-30 11:45     ` Tony Camuso
@ 2015-07-31 17:07     ` Tony Camuso
  1 sibling, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-07-31 17:07 UTC (permalink / raw)
  To: Josh Triplett; +Cc: sparse, linux-sparse

On 07/29/2015 10:55 PM, Josh Triplett wrote:
> On Wed, Jul 29, 2015 at 08:26:41PM -0400, Tony Camuso wrote:
>> Allows building sparse to avert reporting semantic problems, e.g.
>> using sparse as a tokenizer to create a graph of KABI symbols and
>> their dependencies.
>>
>> Signed-off-by: Tony Camuso <tcamuso@redhat.com>
>
> This doesn't seem like something that should be determined at compile
> time.  Ideally, this should be determined at runtime.
>

I will be sending the new patch as a reply to the original, though the
subject line is different, because I'm using the input switches instead
of build-time constants.


^ permalink raw reply	[flat|nested] 36+ messages in thread

* [PATCH 3/3 V2] lib.c: add Wall_off switch
  2015-07-30  0:26 ` [PATCH 3/3] Add NOWARN and NOERR compile conditions Tony Camuso
  2015-07-30  2:55   ` Josh Triplett
@ 2015-07-31 17:12   ` Tony Camuso
  2015-07-31 18:01     ` Tony Camuso
  2015-07-31 19:27   ` [PATCH 3/3 V3] Add Wall_off switch to disable errors and warnings Tony Camuso
  2015-08-03 16:35   ` [PATCH 3/3 v4] " Tony Camuso
  3 siblings, 1 reply; 36+ messages in thread
From: Tony Camuso @ 2015-07-31 17:12 UTC (permalink / raw)
  To: josh, linux-sparse; +Cc: tcamuso, sparse

Disables all warning and error reporting for using sparse as a
tokenizer only.

Signed-off-by: Tony Camuso <tcamuso@redhat.com>
---
 lib.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/lib.c b/lib.c
index 8dc5bcf..c274a68 100644
--- a/lib.c
+++ b/lib.c
@@ -241,6 +241,7 @@ int Wtypesign = 0;
 int Wundef = 0;
 int Wuninitialized = 1;
 int Wvla = 1;
+int Wall_off = 0;
 
 int dbg_entry = 0;
 int dbg_dead = 0;
@@ -464,6 +465,7 @@ static const struct warning {
 	{ "undef", &Wundef },
 	{ "uninitialized", &Wuninitialized },
 	{ "vla", &Wvla },
+	{ "all_off", &Wall_off },
 };
 
 enum {
@@ -479,6 +481,12 @@ static char **handle_onoff_switch(char *arg, char **next, const struct warning w
 	char *p = arg + 1;
 	unsigned i;
 
+	if (!strcmp(p, "all_off")) {
+		for (i = 0; i < n; i++)
+			*warnings[i].flag = WARNING_FORCE_OFF;
+		return NULL;
+	}
+
 	if (!strcmp(p, "sparse-all")) {
 		for (i = 0; i < n; i++) {
 			if (*warnings[i].flag != WARNING_FORCE_OFF && warnings[i].flag != &Wsparse_error)
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3 V2] lib.c: add Wall_off switch
  2015-07-31 17:12   ` [PATCH 3/3 V2] lib.c: add Wall_off switch Tony Camuso
@ 2015-07-31 18:01     ` Tony Camuso
  0 siblings, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-07-31 18:01 UTC (permalink / raw)
  To: josh, linux-sparse; +Cc: sparse

On 07/31/2015 01:12 PM, Tony Camuso wrote:
> Disables all warning and error reporting for using sparse as a
> tokenizer only.
>
> Signed-off-by: Tony Camuso <tcamuso@redhat.com>

Spoke too soon ..

NAK

I'll send an update when I have something that really works.

> ---
>   lib.c | 8 ++++++++
>   1 file changed, 8 insertions(+)
>
> diff --git a/lib.c b/lib.c
> index 8dc5bcf..c274a68 100644
> --- a/lib.c
> +++ b/lib.c
> @@ -241,6 +241,7 @@ int Wtypesign = 0;
>   int Wundef = 0;
>   int Wuninitialized = 1;
>   int Wvla = 1;
> +int Wall_off = 0;
>
>   int dbg_entry = 0;
>   int dbg_dead = 0;
> @@ -464,6 +465,7 @@ static const struct warning {
>   	{ "undef", &Wundef },
>   	{ "uninitialized", &Wuninitialized },
>   	{ "vla", &Wvla },
> +	{ "all_off", &Wall_off },
>   };
>
>   enum {
> @@ -479,6 +481,12 @@ static char **handle_onoff_switch(char *arg, char **next, const struct warning w
>   	char *p = arg + 1;
>   	unsigned i;
>
> +	if (!strcmp(p, "all_off")) {
> +		for (i = 0; i < n; i++)
> +			*warnings[i].flag = WARNING_FORCE_OFF;
> +		return NULL;
> +	}
> +
>   	if (!strcmp(p, "sparse-all")) {
>   		for (i = 0; i < n; i++) {
>   			if (*warnings[i].flag != WARNING_FORCE_OFF && warnings[i].flag != &Wsparse_error)
>


^ permalink raw reply	[flat|nested] 36+ messages in thread

* [PATCH 3/3 V3] Add Wall_off switch to disable errors and warnings
  2015-07-30  0:26 ` [PATCH 3/3] Add NOWARN and NOERR compile conditions Tony Camuso
  2015-07-30  2:55   ` Josh Triplett
  2015-07-31 17:12   ` [PATCH 3/3 V2] lib.c: add Wall_off switch Tony Camuso
@ 2015-07-31 19:27   ` Tony Camuso
  2015-08-01 12:59     ` Sam Ravnborg
  2015-08-03 16:35   ` [PATCH 3/3 v4] " Tony Camuso
  3 siblings, 1 reply; 36+ messages in thread
From: Tony Camuso @ 2015-07-31 19:27 UTC (permalink / raw)
  To: josh, linux-sparse; +Cc: tcamuso, sparse

For using sparse as a tokenizer only. While it still parses semantics,
it doesn't report any semantic errors, which is undesirable for some
tasks like locating the KABI associations in a kernel source file.

Signed-off-by: Tony Camuso <tcamuso@redhat.com>
---
 lib.c   | 20 +++++++++++++++++++-
 lib.h   |  1 +
 parse.c |  4 ++++
 3 files changed, 24 insertions(+), 1 deletion(-)

diff --git a/lib.c b/lib.c
index 8dc5bcf..ef182ae 100644
--- a/lib.c
+++ b/lib.c
@@ -103,6 +103,9 @@ unsigned int hexval(unsigned int c)
 
 static void do_warn(const char *type, struct position pos, const char * fmt, va_list args)
 {
+	if (Wall_off)
+		return;
+
 	static char buffer[512];
 	const char *name;
 
@@ -120,7 +123,7 @@ void info(struct position pos, const char * fmt, ...)
 {
 	va_list args;
 
-	if (!show_info)
+	if (!show_info || Wall_off)
 		return;
 	va_start(args, fmt);
 	do_warn("", pos, fmt, args);
@@ -129,6 +132,9 @@ void info(struct position pos, const char * fmt, ...)
 
 static void do_error(struct position pos, const char * fmt, va_list args)
 {
+	if (Wall_off)
+		return;
+
 	static int errors = 0;
         die_if_error = 1;
 	show_info = 1;
@@ -151,6 +157,9 @@ void warning(struct position pos, const char * fmt, ...)
 {
 	va_list args;
 
+	if (Wall_off)
+		return;
+
 	if (Wsparse_error) {
 		va_start(args, fmt);
 		do_error(pos, fmt, args);
@@ -241,6 +250,7 @@ int Wtypesign = 0;
 int Wundef = 0;
 int Wuninitialized = 1;
 int Wvla = 1;
+int Wall_off = 0;
 
 int dbg_entry = 0;
 int dbg_dead = 0;
@@ -464,6 +474,7 @@ static const struct warning {
 	{ "undef", &Wundef },
 	{ "uninitialized", &Wuninitialized },
 	{ "vla", &Wvla },
+	{ "all_off", &Wall_off },
 };
 
 enum {
@@ -479,6 +490,13 @@ static char **handle_onoff_switch(char *arg, char **next, const struct warning w
 	char *p = arg + 1;
 	unsigned i;
 
+	if (!strcmp(p, "all_off")) {
+		for (i = 0; i < n; i++)
+			*warnings[i].flag = WARNING_FORCE_OFF;
+		Wall_off = 1;
+		return NULL;
+	}
+
 	if (!strcmp(p, "sparse-all")) {
 		for (i = 0; i < n; i++) {
 			if (*warnings[i].flag != WARNING_FORCE_OFF && warnings[i].flag != &Wsparse_error)
diff --git a/lib.h b/lib.h
index 15b69fa..65e4836 100644
--- a/lib.h
+++ b/lib.h
@@ -127,6 +127,7 @@ extern int Wtypesign;
 extern int Wundef;
 extern int Wuninitialized;
 extern int Wvla;
+extern int Wall_off;
 
 extern int dbg_entry;
 extern int dbg_dead;
diff --git a/parse.c b/parse.c
index 02275d8..d70dffb 100644
--- a/parse.c
+++ b/parse.c
@@ -2746,6 +2746,10 @@ struct token *external_declaration(struct token *token, struct symbol_list **lis
 
 	/* Just a type declaration? */
 	if (!ident) {
+
+		if (Wall_off)
+			return token->next;
+
 		warning(token->pos, "missing identifier in declaration");
 		return expect(token, ';', "at the end of type declaration");
 	}
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-07-30 11:45     ` Tony Camuso
@ 2015-07-31 23:46       ` Christopher Li
  2015-08-01 11:09         ` Tony Camuso
  0 siblings, 1 reply; 36+ messages in thread
From: Christopher Li @ 2015-07-31 23:46 UTC (permalink / raw)
  To: Tony Camuso; +Cc: Josh Triplett, Linux-Sparse

On Thu, Jul 30, 2015 at 4:45 AM, Tony Camuso <tcamuso@redhat.com> wrote:
>
> I thought it would be less intrusive, since I don't know how useful
> this would be to others.
>
> If you prefer a switch, I will do that.

I agree that this should be run time behavior.

+
+#if defined NOWARN || defined NOERR
+               return token->next;
+#else

What is up with this change? It is not output warning or not.
It affect the parsing as well. If sparse can't bail out properly,
this should be a separate patch.

Chris

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-07-31 23:46       ` Christopher Li
@ 2015-08-01 11:09         ` Tony Camuso
  2015-08-01 17:52           ` Josh Triplett
  2015-08-01 18:45           ` Christopher Li
  0 siblings, 2 replies; 36+ messages in thread
From: Tony Camuso @ 2015-08-01 11:09 UTC (permalink / raw)
  To: Christopher Li; +Cc: Josh Triplett, Linux-Sparse

On 07/31/2015 07:46 PM, Christopher Li wrote:
> On Thu, Jul 30, 2015 at 4:45 AM, Tony Camuso <tcamuso@redhat.com> wrote:
>>
>> I thought it would be less intrusive, since I don't know how useful
>> this would be to others.
>>
>> If you prefer a switch, I will do that.
>
> I agree that this should be run time behavior.
>
> +
> +#if defined NOWARN || defined NOERR
> +               return token->next;
> +#else
>
> What is up with this change? It is not output warning or not.
> It affect the parsing as well. If sparse can't bail out properly,
> this should be a separate patch.
>
> Chris
>

Hi, Chris.

I've since submitted a runtime patch (3/3 V3) with a switch as a
response to this patch, but it basically does the same thing here.

Consider the case where the source contains something like this...

	struct foo {
		union {
			int number;
			int *pointer;
		};
	};

There being no ident for the union within the struct, we get the warning,
"missing identifier in declaration" etc.

Code without the patch.

	/* Just a type declaration? */
	if (!ident) {
		warning(token->pos, "missing identifier in declaration");
		return expect(token, ';', "at the end of type declaration");
	}
  
Regards,
Tony


^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3 V3] Add Wall_off switch to disable errors and warnings
  2015-07-31 19:27   ` [PATCH 3/3 V3] Add Wall_off switch to disable errors and warnings Tony Camuso
@ 2015-08-01 12:59     ` Sam Ravnborg
  2015-08-01 13:52       ` Tony Camuso
  0 siblings, 1 reply; 36+ messages in thread
From: Sam Ravnborg @ 2015-08-01 12:59 UTC (permalink / raw)
  To: Tony Camuso; +Cc: josh, linux-sparse, sparse

> diff --git a/parse.c b/parse.c
> index 02275d8..d70dffb 100644
> --- a/parse.c
> +++ b/parse.c
> @@ -2746,6 +2746,10 @@ struct token *external_declaration(struct token *token, struct symbol_list **lis
>  
>  	/* Just a type declaration? */
>  	if (!ident) {
> +
> +		if (Wall_off)
> +			return token->next;
> +
>  		warning(token->pos, "missing identifier in declaration");
>  		return expect(token, ';', "at the end of type declaration");

This is on the wrong level.
You need to silence sparse in the spare_error function.

Not on the level where you do the expect() - otherwise you would
have to sprinkle "if (Wall_off)" checks everywhere.

This was also a problem in v1 of the patch.

	Sam

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3 V3] Add Wall_off switch to disable errors and warnings
  2015-08-01 12:59     ` Sam Ravnborg
@ 2015-08-01 13:52       ` Tony Camuso
  0 siblings, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-08-01 13:52 UTC (permalink / raw)
  To: Sam Ravnborg; +Cc: josh, linux-sparse, sparse

On 08/01/2015 08:59 AM, Sam Ravnborg wrote:
>> diff --git a/parse.c b/parse.c
>> index 02275d8..d70dffb 100644
>> --- a/parse.c
>> +++ b/parse.c
>> @@ -2746,6 +2746,10 @@ struct token *external_declaration(struct token *token, struct symbol_list **lis
>>
>>   	/* Just a type declaration? */
>>   	if (!ident) {
>> +
>> +		if (Wall_off)
>> +			return token->next;
>> +
>>   		warning(token->pos, "missing identifier in declaration");
>>   		return expect(token, ';', "at the end of type declaration");
>
> This is on the wrong level.
> You need to silence sparse in the spare_error function.
>
> Not on the level where you do the expect() - otherwise you would
> have to sprinkle "if (Wall_off)" checks everywhere.
>
> This was also a problem in v1 of the patch.
>
> 	Sam
>

Thanks, Sam. Rework in progress ...


^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-08-01 11:09         ` Tony Camuso
@ 2015-08-01 17:52           ` Josh Triplett
  2015-08-01 18:45           ` Christopher Li
  1 sibling, 0 replies; 36+ messages in thread
From: Josh Triplett @ 2015-08-01 17:52 UTC (permalink / raw)
  To: Tony Camuso; +Cc: Christopher Li, Linux-Sparse

On Sat, Aug 01, 2015 at 07:09:06AM -0400, Tony Camuso wrote:
> On 07/31/2015 07:46 PM, Christopher Li wrote:
> >On Thu, Jul 30, 2015 at 4:45 AM, Tony Camuso <tcamuso@redhat.com> wrote:
> >>
> >>I thought it would be less intrusive, since I don't know how useful
> >>this would be to others.
> >>
> >>If you prefer a switch, I will do that.
> >
> >I agree that this should be run time behavior.
> >
> >+
> >+#if defined NOWARN || defined NOERR
> >+               return token->next;
> >+#else
> >
> >What is up with this change? It is not output warning or not.
> >It affect the parsing as well. If sparse can't bail out properly,
> >this should be a separate patch.
> >
> >Chris
> >
> 
> Hi, Chris.
> 
> I've since submitted a runtime patch (3/3 V3) with a switch as a
> response to this patch, but it basically does the same thing here.
> 
> Consider the case where the source contains something like this...
> 
> 	struct foo {
> 		union {
> 			int number;
> 			int *pointer;
> 		};
> 	};
> 
> There being no ident for the union within the struct, we get the warning,
> "missing identifier in declaration" etc.

If so, that's actually a bug in Sparse; anonymous unions should be
allowed without warning:

$ cat test.c
struct foo {
    union {
        int number;
        int *pointer;
    };
};
$ gcc -Wall -Wextra -c test.c -o /dev/null
$

They have a well-defined semantic meaning, and they're standardized in
C11, just not in C89 or C99.

- Josh Triplett

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-08-01 11:09         ` Tony Camuso
  2015-08-01 17:52           ` Josh Triplett
@ 2015-08-01 18:45           ` Christopher Li
  2015-08-02 13:42             ` Tony Camuso
                               ` (2 more replies)
  1 sibling, 3 replies; 36+ messages in thread
From: Christopher Li @ 2015-08-01 18:45 UTC (permalink / raw)
  To: Tony Camuso; +Cc: Josh Triplett, Linux-Sparse

On Sat, Aug 1, 2015 at 4:09 AM, Tony Camuso <tcamuso@redhat.com> wrote:
>
> I've since submitted a runtime patch (3/3 V3) with a switch as a
> response to this patch, but it basically does the same thing here.
>
> Consider the case where the source contains something like this...
>
>         struct foo {
>                 union {
>                         int number;
>                         int *pointer;
>                 };
>         };
>
> There being no ident for the union within the struct, we get the warning,
> "missing identifier in declaration" etc.
>

I can't reproduce the warning with the chrisl repo master branch.

That being said, if there is indeed a bug in sparse, it should be a
separate patch. It changes the parsing behavior.

Thanks

Chris

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-08-01 18:45           ` Christopher Li
@ 2015-08-02 13:42             ` Tony Camuso
  2015-08-02 23:16             ` Tony Camuso
  2015-08-02 23:22             ` Tony Camuso
  2 siblings, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-08-02 13:42 UTC (permalink / raw)
  To: Christopher Li; +Cc: Josh Triplett, Linux-Sparse

On 08/01/2015 02:45 PM, Christopher Li wrote:
> On Sat, Aug 1, 2015 at 4:09 AM, Tony Camuso <tcamuso@redhat.com> wrote:
>>
>> I've since submitted a runtime patch (3/3 V3) with a switch as a
>> response to this patch, but it basically does the same thing here.
>>
>> Consider the case where the source contains something like this...
>>
>>          struct foo {
>>                  union {
>>                          int number;
>>                          int *pointer;
>>                  };
>>          };
>>
>> There being no ident for the union within the struct, we get the warning,
>> "missing identifier in declaration" etc.
>>
>
> I can't reproduce the warning with the chrisl repo master branch.
>
> That being said, if there is indeed a bug in sparse, it should be a
> separate patch. It changes the parsing behavior.
>
> Thanks
>
> Chris
>

I'll isolate exactly where the report is coming from, but it is tripping
over this in parse.c

		warning(token->pos, "missing identifier in declaration");
		return expect(token, ';', "at the end of type declaration");

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-08-01 18:45           ` Christopher Li
  2015-08-02 13:42             ` Tony Camuso
@ 2015-08-02 23:16             ` Tony Camuso
  2015-08-02 23:22             ` Tony Camuso
  2 siblings, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-08-02 23:16 UTC (permalink / raw)
  To: Christopher Li; +Cc: Josh Triplett, Linux-Sparse

On 08/01/2015 02:45 PM, Christopher Li wrote:
> On Sat, Aug 1, 2015 at 4:09 AM, Tony Camuso <tcamuso@redhat.com> wrote:
>>
>> I've since submitted a runtime patch (3/3 V3) with a switch as a
>> response to this patch, but it basically does the same thing here.
>>
>> Consider the case where the source contains something like this...
>>
>>          struct foo {
>>                  union {
>>                          int number;
>>                          int *pointer;
>>                  };
>>          };
>>
>> There being no ident for the union within the struct, we get the warning,
>> "missing identifier in declaration" etc.
>>
>
> I can't reproduce the warning with the chrisl repo master branch.
>
> That being said, if there is indeed a bug in sparse, it should be a
> separate patch. It changes the parsing behavior.
>
> Thanks
>
> Chris
>

This doubt this is a sparse bug. It is an most likely caused by some RHEL
specific macros with encapsulated anonymous unions devised to protect the
Kernel Application Binary Interface while backporting upstream changes
from point release to point release. I can try to convince the KABI macro
maintainers to make their macros sparse-compliant, but I'm hoping you agree
that it might not be a bad idea to provide an option to disable the sparse
error reporting in the meantime.

If you're interested in pursuing this further, these are the errors I'm
seeing, followed by the source that generates them.

/work/linux/fs/bio.i:9137:130: error: Expected ) in function declarator
/work/linux/fs/bio.i:9137:130: error: got (
builtin:0:0: error: expected ; at end of declaration
builtin:0:0: error: expected ; at end of declaration
builtin:0:0: error: expected ; at end of declaration
/work/linux/fs/bio.i:9137:172: error: Expected ; at the end of type declaration
/work/linux/fs/bio.i:9137:172: error: got }
/work/linux/fs/bio.i:9137:209: error: Expected ; at the end of type declaration
/work/linux/fs/bio.i:9137:209: error: got }
/work/linux/fs/bio.i:9137:266: error: Expected ) in function declarator
/work/linux/fs/bio.i:9137:266: error: got (
/work/linux/fs/bio.i:9137:308: error: Expected ; at the end of type declaration
/work/linux/fs/bio.i:9137:308: error: got }
/work/linux/fs/bio.i:9137:350: error: Expected ; at the end of type declaration
/work/linux/fs/bio.i:9137:350: error: got }
/work/linux/fs/bio.i:9137:382: error: Expected ; at the end of type declaration
/work/linux/fs/bio.i:9137:382: error: got }
/work/linux/fs/bio.i:9137:385: error: Expected ; at the end of type declaration
/work/linux/fs/bio.i:9137:385: error: got }
/work/linux/fs/bio.i:9139:1: error: Expected ; at the end of type declaration
/work/linux/fs/bio.i:9139:1: error: got }

The anonymous unions giving us those error messages are encapsulated
in a RHEL-specific macro.

# define _RH_KABI_REPLACE(_orig, _new)                  \
         union {                                         \
                 _new;                                   \
                 struct {                                \
                         _orig;                          \
                 } __UNIQUE_ID(rh_kabi_hide);            \
                 __RH_KABI_CHECK_SIZE_ALIGN(_orig, _new);        \
         }

Here's an example of the macro invocation.

         RH_KABI_REPLACE(void                    *spin_mlock,  /* Spinner MCS lock */
                         struct optimistic_spin_queue  *osq)   /* Spinner MCS lock */


The preprocessor expands it as follows.

  union { struct optimistic_spin_queue *osq; struct { void *spin_mlock; } __UNIQUE_ID_rh_kabi_hide0; union { _Static_assert(sizeof(struct{struct optimistic_spin_queue *osq;}) <= sizeof(struct{void *   spin_mlock;}), "kabi sizeof test panic"); _Static_assert(__alignof__(struct{struct optimistic_spin_queue *osq;}) <= __alignof__(struct{void *spin_mlock;}), "kabi alignof test panic"); }; };



^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-08-01 18:45           ` Christopher Li
  2015-08-02 13:42             ` Tony Camuso
  2015-08-02 23:16             ` Tony Camuso
@ 2015-08-02 23:22             ` Tony Camuso
  2015-08-03 11:23               ` Nicolai Stange
  2 siblings, 1 reply; 36+ messages in thread
From: Tony Camuso @ 2015-08-02 23:22 UTC (permalink / raw)
  To: Christopher Li; +Cc: Josh Triplett, Linux-Sparse

On 08/01/2015 02:45 PM, Christopher Li wrote:
> On Sat, Aug 1, 2015 at 4:09 AM, Tony Camuso <tcamuso@redhat.com> wrote:
>>
>> I've since submitted a runtime patch (3/3 V3) with a switch as a
>> response to this patch, but it basically does the same thing here.
>>
>> Consider the case where the source contains something like this...
>>
>>          struct foo {
>>                  union {
>>                          int number;
>>                          int *pointer;
>>                  };
>>          };
>>
>> There being no ident for the union within the struct, we get the warning,
>> "missing identifier in declaration" etc.
>>
>
> I can't reproduce the warning with the chrisl repo master branch.
>
> That being said, if there is indeed a bug in sparse, it should be a
> separate patch. It changes the parsing behavior.
>
> Thanks
>
> Chris
>

Here's one that might be a sparse bug.

/work/linux/fs/bio.i:5368:26: error: Expected ) at end of cast operator
/work/linux/fs/bio.i:5368:26: error: got __int128

Here is the kernel source in include/linux/math64.h that causes the error.

static inline __attribute__((no_instrument_function)) u64 mul_u64_u32_shr(u64 a, u32 mul, unsigned int shift)
{
  return (u64)(((unsigned __int128)a * mul) >> shift);
}


^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-08-02 23:22             ` Tony Camuso
@ 2015-08-03 11:23               ` Nicolai Stange
  2015-08-03 11:47                 ` Tony Camuso
  0 siblings, 1 reply; 36+ messages in thread
From: Nicolai Stange @ 2015-08-03 11:23 UTC (permalink / raw)
  To: Tony Camuso; +Cc: Christopher Li, Josh Triplett, Linux-Sparse

Hi Tony,

Tony Camuso <tcamuso@redhat.com> writes:
> Here's one that might be a sparse bug.
>
> /work/linux/fs/bio.i:5368:26: error: Expected ) at end of cast operator
> /work/linux/fs/bio.i:5368:26: error: got __int128
>
> Here is the kernel source in include/linux/math64.h that causes the error.
>
> static inline __attribute__((no_instrument_function)) u64 mul_u64_u32_shr(u64 a, u32 mul, unsigned int shift)
> {
>  return (u64)(((unsigned __int128)a * mul) >> shift);
> }

This one is probably triggered by running sparse on gcc -E output.

The mul_u64_u32_shr() implementation cited by you is protected by a
  #if ... && defined(__SIZEOF_INT128__)
in include/linux/math64.h

__SIZEOF_INT128__ is #define'd by gcc but not by sparse.


The reason for your parsing error messages is probably that
declaration_specifiers() does not eat up the __int128, leaving this one
to cast_expression().

Could you please confirm that you did indeed run sparse on gcc -E
output?

Thank you,

Nicolai

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3] Add NOWARN and NOERR compile conditions
  2015-08-03 11:23               ` Nicolai Stange
@ 2015-08-03 11:47                 ` Tony Camuso
  0 siblings, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-08-03 11:47 UTC (permalink / raw)
  To: Nicolai Stange; +Cc: Christopher Li, Josh Triplett, Linux-Sparse

On 08/03/2015 07:23 AM, Nicolai Stange wrote:
> Hi Tony,
>
> Tony Camuso <tcamuso@redhat.com> writes:
>> Here's one that might be a sparse bug.
>>
>> /work/linux/fs/bio.i:5368:26: error: Expected ) at end of cast operator
>> /work/linux/fs/bio.i:5368:26: error: got __int128
>>
>> Here is the kernel source in include/linux/math64.h that causes the error.
>>
>> static inline __attribute__((no_instrument_function)) u64 mul_u64_u32_shr(u64 a, u32 mul, unsigned int shift)
>> {
>>   return (u64)(((unsigned __int128)a * mul) >> shift);
>> }
>
> This one is probably triggered by running sparse on gcc -E output.
>
> The mul_u64_u32_shr() implementation cited by you is protected by a
>    #if ... && defined(__SIZEOF_INT128__)
> in include/linux/math64.h
>
> __SIZEOF_INT128__ is #define'd by gcc but not by sparse.
>
>
> The reason for your parsing error messages is probably that
> declaration_specifiers() does not eat up the __int128, leaving this one
> to cast_expression().
>
> Could you please confirm that you did indeed run sparse on gcc -E
> output?
>
> Thank you,
>
> Nicolai

Yes, we are using -E to generate preprocessor output.


^ permalink raw reply	[flat|nested] 36+ messages in thread

* [PATCH 3/3 v4] Add Wall_off switch to disable errors and warnings
  2015-07-30  0:26 ` [PATCH 3/3] Add NOWARN and NOERR compile conditions Tony Camuso
                     ` (2 preceding siblings ...)
  2015-07-31 19:27   ` [PATCH 3/3 V3] Add Wall_off switch to disable errors and warnings Tony Camuso
@ 2015-08-03 16:35   ` Tony Camuso
  2016-01-05  1:19     ` Luc Van Oostenryck
  3 siblings, 1 reply; 36+ messages in thread
From: Tony Camuso @ 2015-08-03 16:35 UTC (permalink / raw)
  To: sam, linux-sparse; +Cc: josh, sparse, tcamuso

Disable all error reporting. Useful when semantic parsing checks are
being done elsewhere or all you need is a tokenizer.

Signed-off-by: Tony Camuso <tcamuso@redhat.com>
---
 lib.c | 27 +++++++++++++++++++++++----
 lib.h |  1 +
 2 files changed, 24 insertions(+), 4 deletions(-)

diff --git a/lib.c b/lib.c
index 8dc5bcf..08f6a6b 100644
--- a/lib.c
+++ b/lib.c
@@ -101,21 +101,26 @@ unsigned int hexval(unsigned int c)
 	return retval;
 }
 
+static int max_warnings = 100;
+static int show_info = 1;
+
 static void do_warn(const char *type, struct position pos, const char * fmt, va_list args)
 {
 	static char buffer[512];
 	const char *name;
 
-	vsprintf(buffer, fmt, args);	
+	if (Wall_off) {
+		max_warnings = 0;
+		return;
+	}
+
+	vsprintf(buffer, fmt, args);
 	name = stream_name(pos.stream);
 		
 	fprintf(stderr, "%s:%d:%d: %s%s\n",
 		name, pos.line, pos.pos, type, buffer);
 }
 
-static int max_warnings = 100;
-static int show_info = 1;
-
 void info(struct position pos, const char * fmt, ...)
 {
 	va_list args;
@@ -130,6 +135,12 @@ void info(struct position pos, const char * fmt, ...)
 static void do_error(struct position pos, const char * fmt, va_list args)
 {
 	static int errors = 0;
+
+	if (Wall_off) {
+		max_warnings = 0;
+		return;
+	}
+
         die_if_error = 1;
 	show_info = 1;
 	/* Shut up warnings after an error */
@@ -241,6 +252,7 @@ int Wtypesign = 0;
 int Wundef = 0;
 int Wuninitialized = 1;
 int Wvla = 1;
+int Wall_off = 0;
 
 int dbg_entry = 0;
 int dbg_dead = 0;
@@ -479,6 +491,13 @@ static char **handle_onoff_switch(char *arg, char **next, const struct warning w
 	char *p = arg + 1;
 	unsigned i;
 
+	if (!strcmp(p, "all_off")) {
+		for (i = 0; i < n; i++)
+			*warnings[i].flag = WARNING_FORCE_OFF;
+		Wall_off = 1;
+		return NULL;
+	}
+
 	if (!strcmp(p, "sparse-all")) {
 		for (i = 0; i < n; i++) {
 			if (*warnings[i].flag != WARNING_FORCE_OFF && warnings[i].flag != &Wsparse_error)
diff --git a/lib.h b/lib.h
index 15b69fa..65e4836 100644
--- a/lib.h
+++ b/lib.h
@@ -127,6 +127,7 @@ extern int Wtypesign;
 extern int Wundef;
 extern int Wuninitialized;
 extern int Wvla;
+extern int Wall_off;
 
 extern int dbg_entry;
 extern int dbg_dead;
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [PATCH 1/3 v2] .gitignore: add cscope and Qt project files
  2015-07-30  0:26 ` [PATCH 1/3] .gitignore: add cscope and Qt project files Tony Camuso
@ 2015-08-03 17:41   ` Tony Camuso
  2015-08-08  3:58     ` Christopher Li
  2015-08-10 12:33   ` [PATCH 1/3 v3] " Tony Camuso
  1 sibling, 1 reply; 36+ messages in thread
From: Tony Camuso @ 2015-08-03 17:41 UTC (permalink / raw)
  To: linux-sparse; +Cc: tcamuso, sparse

Signed-off-by: Tony Camuso <tcamuso@redhat.com>
---
 .gitignore | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/.gitignore b/.gitignore
index d32d063..1e35eac 100644
--- a/.gitignore
+++ b/.gitignore
@@ -9,6 +9,7 @@
 pre-process.h
 sparse.pc
 version.h
+cscope*
 
 # programs
 test-inspect
@@ -40,3 +41,6 @@ series
 # local makefile
 local.mk
 
+# files related to Qt
+*.pro*
+*.pri*
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* Re: [PATCH 0/3] Minor enhancements and fixes
  2015-07-30  0:26 [PATCH 0/3] Minor enhancements and fixes Tony Camuso
                   ` (2 preceding siblings ...)
  2015-07-30  0:26 ` [PATCH 3/3] Add NOWARN and NOERR compile conditions Tony Camuso
@ 2015-08-03 18:10 ` Tony Camuso
  2015-12-02 18:52 ` Tony Camuso
  4 siblings, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-08-03 18:10 UTC (permalink / raw)
  To: sparse, linux-sparse

On 07/29/2015 08:26 PM, Tony Camuso wrote:
> [PATCH 1/3] .gitignore: add cscope and Qt project files
> Useful if you're using cscope and Qt as an IDE
>
> [PATCH 2/3] c2xml.c, parse.c: gcc 5+ stricter case statement parsing
> The gcc 5.1.1 compiler complains if any of the possible values for the
> switch variable are not covered by the case statement. Basically, it
> forces the employment of the default case.
>
> [PATCH 3/3] Add NOWARN and NOERR compile conditions
> Provides compile conditionals to buid sparse without reporting
> warnings and errors. This isn't quite reducing it to a tokenizer, but
> it has the same effect for our application. Reports from the semantic
> parser and the time they take are undesirable in our application.
>
>   .gitignore |  7 +++++++
>   c2xml.c    |  2 +-
>   lib.c      | 21 +++++++++++++++++++++
>   parse.c    | 13 +++++++++++++
>   4 files changed, 42 insertions(+), 1 deletion(-)
>

Want to update this prologue to detail the differences in the versions
of the patches in this set.

[PATCH 1/3 v2] .gitignore: add cscope and Qt project files
Inadvertently contained local cruft that I didn't really want in the
.gitignore. The sparse maintainers may want to ignore this patch, as
it's not really a big deal.

[PATCH 2/2 v2] Handle all enum members in case statements
Best practice would specify each of the switch variable's enum values
separately, rather than to lump the unhandled ones into a default.

[PATCH 3/3 v4] Add Wall_off switch to disable errors and warnings
The original version of this patch used compile-time constants.

V2 was a first attempt at using a run-time switch to do the same,
but it wasn't tested properly and did not work as expected.

V3 had the run-time Wall_off switch tested at too high a level, which
required it to be placed in more places than necessary.

V4 puts the Wall_off switch at the lowest level and works as expected.

  .gitignore |  4 ++++
  c2xml.c    | 16 ++++++++++++++++
  lib.c      | 27 +++++++++++++++++++++++----
  lib.h      |  1 +
  parse.c    | 15 +++++++++++++++
  5 files changed, 59 insertions(+), 4 deletions(-)


^ permalink raw reply	[flat|nested] 36+ messages in thread

* [PATCH 2/3 v2] Handle all enum members in case statements
  2015-07-30  0:26 ` [PATCH 2/3] c2xml.c, parse.c: gcc 5+ stricter case statement parsing Tony Camuso
@ 2015-08-04 12:06   ` Tony Camuso
  2015-08-04 23:31     ` Christopher Li
  2015-08-10 12:35   ` [PATCH 2/3 v3] Add default case to switches on enum variables Tony Camuso
  1 sibling, 1 reply; 36+ messages in thread
From: Tony Camuso @ 2015-08-04 12:06 UTC (permalink / raw)
  To: sparse, linux-sparse; +Cc: tcamuso, nicstange

Missing enum members in case statements in c2xml.c and parse.c were
causing compile time complaints by gcc 5.1.1. Better to explicitly
handle all enum members of the switch variable in case statements,
even if they just break.

Signed-off-by: Tony Camuso <tcamuso@redhat.com>
---
 c2xml.c | 16 ++++++++++++++++
 parse.c | 15 +++++++++++++++
 2 files changed, 31 insertions(+)

diff --git a/c2xml.c b/c2xml.c
index 67486c7..a53f5bd 100644
--- a/c2xml.c
+++ b/c2xml.c
@@ -214,6 +214,22 @@ static void examine_symbol(struct symbol *sym, xmlNodePtr node)
 	case SYM_UNINITIALIZED:
 		newProp(child, "base-type-builtin", builtin_typename(sym));
 		break;
+	case SYM_PREPROCESSOR:
+	case SYM_BASETYPE:
+	case SYM_NODE:
+	case SYM_PTR:
+	case SYM_ARRAY:
+	case SYM_ENUM:
+	case SYM_TYPEDEF:
+	case SYM_TYPEOF:
+	case SYM_MEMBER:
+	case SYM_BITFIELD:
+	case SYM_LABEL:
+	case SYM_RESTRICT:
+	case SYM_FOULED:
+	case SYM_KEYWORD:
+	case SYM_BAD:
+		break;
 	}
 	return;
 }
diff --git a/parse.c b/parse.c
index b43d683..74a56e4 100644
--- a/parse.c
+++ b/parse.c
@@ -2769,6 +2769,21 @@ struct token *external_declaration(struct token *token, struct symbol_list **lis
 			case SYM_ENUM:
 			case SYM_RESTRICT:
 				base_type->ident = ident;
+			case SYM_PREPROCESSOR:
+			case SYM_BASETYPE:
+			case SYM_NODE:
+			case SYM_PTR:
+			case SYM_FN:
+			case SYM_ARRAY:
+			case SYM_TYPEDEF:
+			case SYM_TYPEOF:
+			case SYM_MEMBER:
+			case SYM_BITFIELD:
+			case SYM_LABEL:
+			case SYM_FOULED:
+			case SYM_KEYWORD:
+			case SYM_BAD:
+				break;
 			}
 		}
 	} else if (base_type && base_type->type == SYM_FN) {
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* Re: [PATCH 2/3 v2] Handle all enum members in case statements
  2015-08-04 12:06   ` [PATCH 2/3 v2] Handle all enum members in case statements Tony Camuso
@ 2015-08-04 23:31     ` Christopher Li
  2015-08-04 23:52       ` Tony Camuso
  0 siblings, 1 reply; 36+ messages in thread
From: Christopher Li @ 2015-08-04 23:31 UTC (permalink / raw)
  To: Tony Camuso; +Cc: Linux-Sparse, nicstange

On Tue, Aug 4, 2015 at 8:06 AM, Tony Camuso <tcamuso@redhat.com> wrote:
> Missing enum members in case statements in c2xml.c and parse.c were
> causing compile time complaints by gcc 5.1.1. Better to explicitly
> handle all enum members of the switch variable in case statements,
> even if they just break.
>                 break;
> +       case SYM_PREPROCESSOR:
> +       case SYM_BASETYPE:
> +       case SYM_NODE:
> +       case SYM_PTR:
> +       case SYM_ARRAY:
> +       case SYM_ENUM:
> +       case SYM_TYPEDEF:
> +       case SYM_TYPEOF:
> +       case SYM_MEMBER:
> +       case SYM_BITFIELD:
> +       case SYM_LABEL:
> +       case SYM_RESTRICT:
> +       case SYM_FOULED:
> +       case SYM_KEYWORD:
> +       case SYM_BAD:
> +               break;

I think adding a "default: break" should work. I like your previous patch
better, except maybe adding a line break after default.


>                         case SYM_ENUM:
>                         case SYM_RESTRICT:
>                                 base_type->ident = ident;
> +                       case SYM_PREPROCESSOR:
> +                       case SYM_BASETYPE:

I notice this has the follow through behavior. It is not a bug.
But if some one append some new case there, it is easy to
cause unintended follow through. It is better add a break there.

Chris

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 2/3 v2] Handle all enum members in case statements
  2015-08-04 23:31     ` Christopher Li
@ 2015-08-04 23:52       ` Tony Camuso
       [not found]         ` <CANeU7Q=QAtRqDP36k8uOd9_XgzqjJ0du5SO2WpMEcjp8+mg3CQ@mail.gmail.com>
  0 siblings, 1 reply; 36+ messages in thread
From: Tony Camuso @ 2015-08-04 23:52 UTC (permalink / raw)
  To: Christopher Li; +Cc: Linux-Sparse, nicstange


On 08/04/2015 07:31 PM, Christopher Li wrote:
> On Tue, Aug 4, 2015 at 8:06 AM, Tony Camuso <tcamuso@redhat.com> wrote:
>> Missing enum members in case statements in c2xml.c and parse.c were
>> causing compile time complaints by gcc 5.1.1. Better to explicitly
>> handle all enum members of the switch variable in case statements,
>> even if they just break.
>>                  break;
>> +       case SYM_PREPROCESSOR:
>> +       case SYM_BASETYPE:
>> +       case SYM_NODE:
>> +       case SYM_PTR:
>> +       case SYM_ARRAY:
>> +       case SYM_ENUM:
>> +       case SYM_TYPEDEF:
>> +       case SYM_TYPEOF:
>> +       case SYM_MEMBER:
>> +       case SYM_BITFIELD:
>> +       case SYM_LABEL:
>> +       case SYM_RESTRICT:
>> +       case SYM_FOULED:
>> +       case SYM_KEYWORD:
>> +       case SYM_BAD:
>> +               break;
>
> I think adding a "default: break" should work. I like your previous patch
> better, except maybe adding a line break after default.
>

It was mentioned to me that the new prevailing wisdom is to "Prefer
compile time errors to runtime errors", such that each enum'd value
of a switch variable should be explicitly handled.

I seem to have violated the spirit of that paradigm by using fall through.

I could add a new line and "break" statement after each case.

Or, if you prefer, I can resubmit the original patch with a linefeed after
the "default:" for good form. Either way, I believe the compiler optimize
them the same.

>
>>                          case SYM_ENUM:
>>                          case SYM_RESTRICT:
>>                                  base_type->ident = ident;
>> +                       case SYM_PREPROCESSOR:
>> +                       case SYM_BASETYPE:
>
> I notice this has the follow through behavior. It is not a bug.
> But if some one append some new case there, it is easy to
> cause unintended follow through. It is better add a break there.

It may not be a bug today, but without an explicit break for each,
it's a potential bug.

The whole reason for explicitly listing the existing enum members is so
that new cases for which "break" may not be the correct solution can be
easily identified at compile time.

Tony



^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 1/3 v2] .gitignore: add cscope and Qt project files
  2015-08-03 17:41   ` [PATCH 1/3 v2] " Tony Camuso
@ 2015-08-08  3:58     ` Christopher Li
  2015-08-10 11:18       ` Tony Camuso
  0 siblings, 1 reply; 36+ messages in thread
From: Christopher Li @ 2015-08-08  3:58 UTC (permalink / raw)
  To: Tony Camuso; +Cc: Linux-Sparse

On Mon, Aug 3, 2015 at 1:41 PM, Tony Camuso <tcamuso@redhat.com> wrote:
>
> Signed-off-by: Tony Camuso <tcamuso@redhat.com>
> ---
>  .gitignore | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/.gitignore b/.gitignore
> index d32d063..1e35eac 100644
> --- a/.gitignore
> +++ b/.gitignore
> @@ -9,6 +9,7 @@
>  pre-process.h
>  sparse.pc
>  version.h
> +cscope*


Can we be more specific on the cscope files?
e.g. Will cscope.* works for you?

Just in case we can have some C file which starts
with "cscope". We do have "ctags.c" for example.

Chris

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 2/3 v2] Handle all enum members in case statements
       [not found]         ` <CANeU7Q=QAtRqDP36k8uOd9_XgzqjJ0du5SO2WpMEcjp8+mg3CQ@mail.gmail.com>
@ 2015-08-10 11:16           ` Tony Camuso
  0 siblings, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-08-10 11:16 UTC (permalink / raw)
  To: Christopher Li; +Cc: Linux-Sparse, Nicolai Stange

On 08/07/2015 11:47 PM, Christopher Li wrote:
>
>
> On Tue, Aug 4, 2015 at 7:52 PM, Tony Camuso <tcamuso@redhat.com <mailto:tcamuso@redhat.com>> wrote:
>  >
>  > It was mentioned to me that the new prevailing wisdom is to "Prefer
>  > compile time errors to runtime errors", such that each enum'd value
>  > of a switch variable should be explicitly handled.
>
> Most of the code I saw, when using fail through, has comment emphasizing
> the fall through behavior.
>
>
>  > Or, if you prefer, I can resubmit the original patch with a linefeed after
>  > the "default:" for good form. Either way, I believe the compiler optimize
>  > them the same.
>
> Yes, I prefer the patch without have to list every enum member just to
> skip them.
>
>  > The whole reason for explicitly listing the existing enum members is so
>  > that new cases for which "break" may not be the correct solution can be
>  > easily identified at compile time.
>
> I can see that. However it only works for the switch statement that does
> not have the default handler already. In the field a lot of the switch statements
> already have default handler, depending on the compiler to give warning is
> not that reliable. Unless we ban the default handler all together.
>
> Chris
>

Thanks Chris,

I will resubmit the original patch with your recommendation for a newline
after the default: case.

Regards,
Tony

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 1/3 v2] .gitignore: add cscope and Qt project files
  2015-08-08  3:58     ` Christopher Li
@ 2015-08-10 11:18       ` Tony Camuso
  0 siblings, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-08-10 11:18 UTC (permalink / raw)
  To: Christopher Li; +Cc: Linux-Sparse

On 08/07/2015 11:58 PM, Christopher Li wrote:
> On Mon, Aug 3, 2015 at 1:41 PM, Tony Camuso <tcamuso@redhat.com> wrote:
>>
>> Signed-off-by: Tony Camuso <tcamuso@redhat.com>
>> ---
>>   .gitignore | 4 ++++
>>   1 file changed, 4 insertions(+)
>>
>> diff --git a/.gitignore b/.gitignore
>> index d32d063..1e35eac 100644
>> --- a/.gitignore
>> +++ b/.gitignore
>> @@ -9,6 +9,7 @@
>>   pre-process.h
>>   sparse.pc
>>   version.h
>> +cscope*
>
>
> Can we be more specific on the cscope files?
> e.g. Will cscope.* works for you?
>
> Just in case we can have some C file which starts
> with "cscope". We do have "ctags.c" for example.
>
> Chris
>

Yes, very good point. You also have scope.c and scope.h

cscope.out is the generated file, so I will correct this patch
for that.

Regards,
Tony


^ permalink raw reply	[flat|nested] 36+ messages in thread

* [PATCH 1/3 v3] .gitignore: add cscope and Qt project files
  2015-07-30  0:26 ` [PATCH 1/3] .gitignore: add cscope and Qt project files Tony Camuso
  2015-08-03 17:41   ` [PATCH 1/3 v2] " Tony Camuso
@ 2015-08-10 12:33   ` Tony Camuso
  1 sibling, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-08-10 12:33 UTC (permalink / raw)
  To: linux-sparse; +Cc: tcamuso, sparse

Signed-off-by: Tony Camuso <tcamuso@redhat.com>
---
 .gitignore | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/.gitignore b/.gitignore
index d32d063..44218a2 100644
--- a/.gitignore
+++ b/.gitignore
@@ -40,3 +40,6 @@ series
 # local makefile
 local.mk
 
+# cscope and Qt files
+cscope.out
+*.pro*
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [PATCH 2/3 v3] Add default case to switches on enum variables
  2015-07-30  0:26 ` [PATCH 2/3] c2xml.c, parse.c: gcc 5+ stricter case statement parsing Tony Camuso
  2015-08-04 12:06   ` [PATCH 2/3 v2] Handle all enum members in case statements Tony Camuso
@ 2015-08-10 12:35   ` Tony Camuso
  1 sibling, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2015-08-10 12:35 UTC (permalink / raw)
  To: linux-sparse; +Cc: tcamuso, sparse, nicstange

Missing enum members in case statements in c2xml.c and parse.c were
causing compile time complaints by gcc 5.1.1. Adding a default case
satisfies the compiler and notifies the reviewer that there are
cases not explicitly mentioned being handled by the default case.

Signed-off-by: Tony Camuso <tcamuso@redhat.com>

---
 c2xml.c | 3 ++-
 parse.c | 2 ++
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/c2xml.c b/c2xml.c
index 67486c7..c45d581 100644
--- a/c2xml.c
+++ b/c2xml.c
@@ -214,6 +214,8 @@ static void examine_symbol(struct symbol *sym, xmlNodePtr node)
 	case SYM_UNINITIALIZED:
 		newProp(child, "base-type-builtin", builtin_typename(sym));
 		break;
+	default:
+		break;
 	}
 	return;
 }
@@ -330,4 +332,3 @@ int main(int argc, char **argv)
 
 	return 0;
 }

^ permalink raw reply related	[flat|nested] 36+ messages in thread

* Re: [PATCH 0/3] Minor enhancements and fixes
  2015-07-30  0:26 [PATCH 0/3] Minor enhancements and fixes Tony Camuso
                   ` (3 preceding siblings ...)
  2015-08-03 18:10 ` [PATCH 0/3] Minor enhancements and fixes Tony Camuso
@ 2015-12-02 18:52 ` Tony Camuso
  2016-02-02 18:54   ` Christopher Li
  4 siblings, 1 reply; 36+ messages in thread
From: Tony Camuso @ 2015-12-02 18:52 UTC (permalink / raw)
  To: sparse, linux-sparse

On 07/29/2015 08:26 PM, Tony Camuso wrote:
> [PATCH 1/3] .gitignore: add cscope and Qt project files
> Useful if you're using cscope and Qt as an IDE
>
> [PATCH 2/3] c2xml.c, parse.c: gcc 5+ stricter case statement parsing
> The gcc 5.1.1 compiler complains if any of the possible values for the
> switch variable are not covered by the case statement. Basically, it
> forces the employment of the default case.
>
> [PATCH 3/3] Add NOWARN and NOERR compile conditions
> Provides compile conditionals to buid sparse without reporting
> warnings and errors. This isn't quite reducing it to a tokenizer, but
> it has the same effect for our application. Reports from the semantic
> parser and the time they take are undesirable in our application.
>
>   .gitignore |  7 +++++++
>   c2xml.c    |  2 +-
>   lib.c      | 21 +++++++++++++++++++++
>   parse.c    | 13 +++++++++++++
>   4 files changed, 42 insertions(+), 1 deletion(-)
>

Any chance of this patchset being committed to sparse?

Regards,
Tony



^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3 v4] Add Wall_off switch to disable errors and warnings
  2015-08-03 16:35   ` [PATCH 3/3 v4] " Tony Camuso
@ 2016-01-05  1:19     ` Luc Van Oostenryck
  2016-01-13 14:39       ` Tony Camuso
  0 siblings, 1 reply; 36+ messages in thread
From: Luc Van Oostenryck @ 2016-01-05  1:19 UTC (permalink / raw)
  To: Tony Camuso; +Cc: sam, linux-sparse, josh, sparse

On Mon, Aug 03, 2015 at 12:35:59PM -0400, Tony Camuso wrote:
> Disable all error reporting. Useful when semantic parsing checks are
> being done elsewhere or all you need is a tokenizer.
> 
> Signed-off-by: Tony Camuso <tcamuso@redhat.com>
> ---
>  lib.c | 27 +++++++++++++++++++++++----
>  lib.h |  1 +
>  2 files changed, 24 insertions(+), 4 deletions(-)
> 
> diff --git a/lib.c b/lib.c
> index 8dc5bcf..08f6a6b 100644
> --- a/lib.c
> +++ b/lib.c

...

> @@ -130,6 +135,12 @@ void info(struct position pos, const char * fmt, ...)
>  static void do_error(struct position pos, const char * fmt, va_list args)
>  {
>  	static int errors = 0;
> +
> +	if (Wall_off) {
> +		max_warnings = 0;
> +		return;
> +	}
> +

Is this really needed?
The same check in do_warn should be enough to quiet all messages, isn't it?


> @@ -479,6 +491,13 @@ static char **handle_onoff_switch(char *arg, char **next, const struct warning w
>  	char *p = arg + 1;
>  	unsigned i;
>  
> +	if (!strcmp(p, "all_off")) {
> +		for (i = 0; i < n; i++)
> +			*warnings[i].flag = WARNING_FORCE_OFF;
> +		Wall_off = 1;
> +		return NULL;
> +	}
> +

Can't you simply set max_warnings to 0 already here
instead of doing it in do_warn()?

> @@ -127,6 +127,7 @@ extern int Wtypesign;
>  extern int Wundef;
>  extern int Wuninitialized;
>  extern int Wvla;
> +extern int Wall_off;

I think it should be better to use a much more explicit name,
something like "ignore_all_warnings" for example.

Also it would be nice to document this new option in the man page.


Regards,
Luc

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 3/3 v4] Add Wall_off switch to disable errors and warnings
  2016-01-05  1:19     ` Luc Van Oostenryck
@ 2016-01-13 14:39       ` Tony Camuso
  0 siblings, 0 replies; 36+ messages in thread
From: Tony Camuso @ 2016-01-13 14:39 UTC (permalink / raw)
  To: Luc Van Oostenryck; +Cc: sam, linux-sparse, josh, sparse

On 01/04/2016 08:19 PM, Luc Van Oostenryck wrote:
> On Mon, Aug 03, 2015 at 12:35:59PM -0400, Tony Camuso wrote:
>> Disable all error reporting. Useful when semantic parsing checks are
>> being done elsewhere or all you need is a tokenizer.
>>
>> Signed-off-by: Tony Camuso <tcamuso@redhat.com>
>> ---
>>   lib.c | 27 +++++++++++++++++++++++----
>>   lib.h |  1 +
>>   2 files changed, 24 insertions(+), 4 deletions(-)
>>
>> diff --git a/lib.c b/lib.c
>> index 8dc5bcf..08f6a6b 100644
>> --- a/lib.c
>> +++ b/lib.c
>
> ...
>
>> @@ -130,6 +135,12 @@ void info(struct position pos, const char * fmt, ...)
>>   static void do_error(struct position pos, const char * fmt, va_list args)
>>   {
>>   	static int errors = 0;
>> +
>> +	if (Wall_off) {
>> +		max_warnings = 0;
>> +		return;
>> +	}
>> +
>
> Is this really needed?
> The same check in do_warn should be enough to quiet all messages, isn't it?

I'll test again to be certain, but IIRC, I needed it there, too.
If I don't need it there, I will drop it in a new version of the
patch.

>
>> @@ -479,6 +491,13 @@ static char **handle_onoff_switch(char *arg, char **next, const struct warning w
>>   	char *p = arg + 1;
>>   	unsigned i;
>>
>> +	if (!strcmp(p, "all_off")) {
>> +		for (i = 0; i < n; i++)
>> +			*warnings[i].flag = WARNING_FORCE_OFF;
>> +		Wall_off = 1;
>> +		return NULL;
>> +	}
>> +
>
> Can't you simply set max_warnings to 0 already here
> instead of doing it in do_warn()?

Yes, I will do that. It does make more sense in that block.

>> @@ -127,6 +127,7 @@ extern int Wtypesign;
>>   extern int Wundef;
>>   extern int Wuninitialized;
>>   extern int Wvla;
>> +extern int Wall_off;
>
> I think it should be better to use a much more explicit name,
> something like "ignore_all_warnings" for example.

Also will do that.

> Also it would be nice to document this new option in the man page.

I'll add this to the patch.

>
> Regards,
> Luc
>

Ciao,
Tony

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [PATCH 0/3] Minor enhancements and fixes
  2015-12-02 18:52 ` Tony Camuso
@ 2016-02-02 18:54   ` Christopher Li
  0 siblings, 0 replies; 36+ messages in thread
From: Christopher Li @ 2016-02-02 18:54 UTC (permalink / raw)
  To: Tony Camuso; +Cc: Linux-Sparse

On Thu, Dec 3, 2015 at 2:52 AM, Tony Camuso <tcamuso@redhat.com> wrote:
>
> Any chance of this patchset being committed to sparse?
>

Better late than never. It has been sitting on my laptop for a long
time.

I add some minor modification to the last patch.

Applied and pushed.

Chris

^ permalink raw reply	[flat|nested] 36+ messages in thread

end of thread, other threads:[~2016-02-02 18:54 UTC | newest]

Thread overview: 36+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-07-30  0:26 [PATCH 0/3] Minor enhancements and fixes Tony Camuso
2015-07-30  0:26 ` [PATCH 1/3] .gitignore: add cscope and Qt project files Tony Camuso
2015-08-03 17:41   ` [PATCH 1/3 v2] " Tony Camuso
2015-08-08  3:58     ` Christopher Li
2015-08-10 11:18       ` Tony Camuso
2015-08-10 12:33   ` [PATCH 1/3 v3] " Tony Camuso
2015-07-30  0:26 ` [PATCH 2/3] c2xml.c, parse.c: gcc 5+ stricter case statement parsing Tony Camuso
2015-08-04 12:06   ` [PATCH 2/3 v2] Handle all enum members in case statements Tony Camuso
2015-08-04 23:31     ` Christopher Li
2015-08-04 23:52       ` Tony Camuso
     [not found]         ` <CANeU7Q=QAtRqDP36k8uOd9_XgzqjJ0du5SO2WpMEcjp8+mg3CQ@mail.gmail.com>
2015-08-10 11:16           ` Tony Camuso
2015-08-10 12:35   ` [PATCH 2/3 v3] Add default case to switches on enum variables Tony Camuso
2015-07-30  0:26 ` [PATCH 3/3] Add NOWARN and NOERR compile conditions Tony Camuso
2015-07-30  2:55   ` Josh Triplett
2015-07-30 11:45     ` Tony Camuso
2015-07-31 23:46       ` Christopher Li
2015-08-01 11:09         ` Tony Camuso
2015-08-01 17:52           ` Josh Triplett
2015-08-01 18:45           ` Christopher Li
2015-08-02 13:42             ` Tony Camuso
2015-08-02 23:16             ` Tony Camuso
2015-08-02 23:22             ` Tony Camuso
2015-08-03 11:23               ` Nicolai Stange
2015-08-03 11:47                 ` Tony Camuso
2015-07-31 17:07     ` Tony Camuso
2015-07-31 17:12   ` [PATCH 3/3 V2] lib.c: add Wall_off switch Tony Camuso
2015-07-31 18:01     ` Tony Camuso
2015-07-31 19:27   ` [PATCH 3/3 V3] Add Wall_off switch to disable errors and warnings Tony Camuso
2015-08-01 12:59     ` Sam Ravnborg
2015-08-01 13:52       ` Tony Camuso
2015-08-03 16:35   ` [PATCH 3/3 v4] " Tony Camuso
2016-01-05  1:19     ` Luc Van Oostenryck
2016-01-13 14:39       ` Tony Camuso
2015-08-03 18:10 ` [PATCH 0/3] Minor enhancements and fixes Tony Camuso
2015-12-02 18:52 ` Tony Camuso
2016-02-02 18:54   ` Christopher Li

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.