From 0f810834381a67595d8b61383184259e537e996c Mon Sep 17 00:00:00 2001 From: Albert Cheng Date: Mon, 5 Apr 2010 16:44:31 -0500 Subject: [svn-r18516] Bug: PGI v10.2 in Red Storm Qual complained about the H5_IS_API macro with the following message when -Mbounds is used: PGC-S-0053-Illegal use of void type The compiler did not like to treat the literal strings as arrays. The -Mbounds option is used when --disable-production is used. Solution: Casted all the literal to (char *). Tested: h5committest passed (linew is not quite completed yet.) Red Storm Qual passed with the fixed H5_IS_API macro though it has other failures later. Will be fixed in another batch. --- src/H5private.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/H5private.h b/src/H5private.h index 860e8ac..c8de6bf 100644 --- a/src/H5private.h +++ b/src/H5private.h @@ -1637,7 +1637,7 @@ H5_DLL double H5_trace(const double *calltime, const char *func, const char *typ /* `S' is the name of a function which is being tested to check if its */ /* an API function */ -#define H5_IS_API(S) ('_'!=S[2] && '_'!=S[3] && (!S[4] || '_'!=S[4])) +#define H5_IS_API(S) ('_'!=((char*)S)[2] && '_'!=((char*)S)[3] && (!((char*)S)[4] || '_'!=((char*)S)[4])) /* global library version information string */ extern char H5_lib_vers_info_g[]; -- cgit v0.12