Unverified Commit 32ec3063 authored by Marcel Raad's avatar Marcel Raad
Browse files

curl-compilers.m4: enable missing-variable-declarations clang warning

It usually warns when forgetting to declare TU-local variables static.

Closes https://github.com/curl/curl/pull/1578
parent b5c5909f
Loading
Loading
Loading
Loading
+5 −0
Original line number Original line Diff line number Diff line
@@ -892,6 +892,11 @@ AC_DEFUN([CURL_SET_COMPILER_WARNING_OPTS], [
            tmp_CFLAGS="$tmp_CFLAGS -Wshift-sign-overflow"
            tmp_CFLAGS="$tmp_CFLAGS -Wshift-sign-overflow"
          fi
          fi
          #
          #
          dnl Only clang 3.2 or later
          if test "$compiler_num" -ge "302"; then
            tmp_CFLAGS="$tmp_CFLAGS -Wmissing-variable-declarations"
          fi
          #
          dnl Only clang 3.6 or later
          dnl Only clang 3.6 or later
          if test "$compiler_num" -ge "306"; then
          if test "$compiler_num" -ge "306"; then
            tmp_CFLAGS="$tmp_CFLAGS -Wdouble-promotion"
            tmp_CFLAGS="$tmp_CFLAGS -Wdouble-promotion"