git-compat-util.h: avoid using c99 flex array feature with Sun compiler 5.8
[gitweb.git] / git-compat-util.h
index 71197d9774b284fe1dc20ada31fb766b7e829b1d..48d99fab863eb2462a266cd1bac31d88ffd59f8d 100644 (file)
@@ -7,7 +7,7 @@
 /*
  * See if our compiler is known to support flexible array members.
  */
-#if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L)
+#if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L) && (!defined(__SUNPRO_C) || (__SUNPRO_C > 0x580))
 # define FLEX_ARRAY /* empty */
 #elif defined(__GNUC__)
 # if (__GNUC__ >= 3)