suggest braces around initialization of subobject

Jonathan,
      We have one instance of the warning...

/sw/src/fink.build/llvm37-3.7.0-100/llvm-3.7.0.src/projects/openmp/runtime/src/kmp_global.c:374:32:
warning: suggest braces around initialization of subobject
      [-Wmissing-braces]
kmp_global_t __kmp_global = {{ 0 }};
                               ^
                               {}

in the build of openmp under the clang compilers. This can be silenced
with the attached patch.
            Jack
ps We also have some warnings about missing field initializer in this file...

/sw/src/fink.build/llvm37-3.7.0-100/llvm-3.7.0.src/projects/openmp/runtime/src/kmp_global.c:24:37:
warning: missing field 'signature' initializer
      [-Wmissing-field-initializers]
kmp_cpuinfo_t __kmp_cpuinfo = { 0 }; // Not initialized
                                    ^
/sw/src/fink.build/llvm37-3.7.0-100/llvm-3.7.0.src/projects/openmp/runtime/src/kmp_global.c:374:34:
warning: missing field 'g_abort' initializer
      [-Wmissing-field-initializers]
kmp_global_t __kmp_global = {{ 0 }};
                                 ^
/sw/src/fink.build/llvm37-3.7.0-100/llvm-3.7.0.src/projects/openmp/runtime/src/kmp_global.c:404:43:
warning: missing field 'flags' initializer
      [-Wmissing-field-initializers]
kmp_bootstrap_lock_t __kmp_initz_lock =
KMP_BOOTSTRAP_LOCK_INITIALIZER( __kmp_initz_lock ); /* Control
initializations */
                                          ^
but these seem to be unsolvable...

http://clang-developers.42468.n3.nabble.com/Wmissing-field-initializers-td3761260.html

short of converting runtime/src/kmp_global.c into
runtime/src/kmp_global.cpp so that it is compiled with the c++
compiler instead.

missing-braces.diff (519 Bytes)