[2/4] app: add extension keyword to statement expressions

Message ID 1700089378-26197-3-git-send-email-roretzla@linux.microsoft.com (mailing list archive)
State Superseded
Delegated to: David Marchand
Headers
Series add __extension__ keyword to statement expressions |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Tyler Retzlaff Nov. 15, 2023, 11:02 p.m. UTC
  Add __extension__ keyword to gcc statement expression extensions.

Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 app/graph/utils.c          | 2 +-
 app/test-eventdev/parser.h | 2 +-
 app/test-mldev/parser.h    | 2 +-
 app/test-pmd/cmdline_tm.c  | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)
  

Patch

diff --git a/app/graph/utils.c b/app/graph/utils.c
index c7b6ae8..28fb062 100644
--- a/app/graph/utils.c
+++ b/app/graph/utils.c
@@ -13,7 +13,7 @@ 
 #include "module_api.h"
 
 #define white_spaces_skip(pos)			\
-({						\
+__extension__ ({				\
 	__typeof__(pos) _p = (pos);		\
 	for ( ; isspace(*_p); _p++)		\
 		;				\
diff --git a/app/test-eventdev/parser.h b/app/test-eventdev/parser.h
index 3617872..a1c13ca 100644
--- a/app/test-eventdev/parser.h
+++ b/app/test-eventdev/parser.h
@@ -11,7 +11,7 @@ 
 #define PARSE_DELIMITER				" \f\n\r\t\v"
 
 #define skip_white_spaces(pos)			\
-({						\
+__extension__ ({				\
 	__typeof__(pos) _p = (pos);		\
 	for ( ; isspace(*_p); _p++)		\
 		;				\
diff --git a/app/test-mldev/parser.h b/app/test-mldev/parser.h
index 8b4207d..e1e0713 100644
--- a/app/test-mldev/parser.h
+++ b/app/test-mldev/parser.h
@@ -13,7 +13,7 @@ 
 #define PARSE_DELIMITER " \f\n\r\t\v"
 
 #define skip_white_spaces(pos) \
-	({ \
+	__extension__ ({ \
 		__typeof__(pos) _p = (pos); \
 		for (; isspace(*_p); _p++) \
 			; \
diff --git a/app/test-pmd/cmdline_tm.c b/app/test-pmd/cmdline_tm.c
index c11c80b..2a6a20c 100644
--- a/app/test-pmd/cmdline_tm.c
+++ b/app/test-pmd/cmdline_tm.c
@@ -20,7 +20,7 @@ 
 #define MAX_NUM_SHARED_SHAPERS		256
 
 #define skip_white_spaces(pos)			\
-({						\
+__extension__ ({				\
 	__typeof__(pos) _p = (pos);		\
 	for ( ; isspace(*_p); _p++)		\
 		;				\