[prev in list] [next in list] [prev in thread] [next in thread]
List: linux-sparse
Subject: [PATCH] compile sparse with Intel C
From: Mikulas Patocka <mikulas () artax ! karlin ! mff ! cuni ! cz>
Date: 2012-06-20 0:24:15
Message-ID: alpine.DEB.2.00.1206200221060.7055 () artax ! karlin ! mff ! cuni ! cz
[Download RAW message or body]
Hi
This patch makes sparse compile with Intel C compiler.
Intel C complains that it cannot initialize flexible arrays (defined at
the end of the structure with []).
Mikulas
--- dissect.h_ 2012-06-20 01:31:19.000000000 +0200
+++ dissect.h 2012-06-20 02:19:42.000000000 +0200
@@ -2,6 +2,7 @@
#define DISSECT_H
#include <stdio.h>
+#include <string.h>
#include "parse.h"
#include "expression.h"
@@ -32,8 +33,8 @@
char __[sizeof(s)]; \
} ident = {{ \
.len = sizeof(s)-1, \
- .name = s, \
}}; \
+ strcpy(ident.ident.name, s); \
&ident.ident; \
})
--
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
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic