
C++ Compilers are becoming more and more intelligent (or at least believe so).
In the last years, GNU APL has been plagued with a growing number of bogus
C++ compiler warnings that break the build process of GNU APL.

Some years ago, GNU APL decided to build with -Wall which causes all warnings
to be treated as errors. It was a lot of effort to get to the point where
GNU APL would compile on practically all platforms with -Wall, but this was,
at that time, done as a means to improve GNU APL's code quality.

In general GNU APL tries to deal with newly invented compiler warnings and
also with bogus ones as long there is a reasonably simple way to fix them
and the perfomance of GNU APL is not negatively affected.

Sometimes, however, that is not possible. There exist warnings that would
either require obscuring the code (by #ifdefs all over the place) or by
unavoidibly impacting the performance of GNU APL. In these cases, instead
of changing the GNU APL source code, examples of where these warnings have
occured (and how they can be suppressed) are listed below.

Note however, that the majority of warnings might make sense in other
circumstances, therefore suppressing them always has the risk of real
problems noty being reported. The cases listed below are those where we
had closely looked at the code and came to the conclusion that the
warning was bogus.

In general a bogus compiler warning (we assume the compiler is GNU g++) is
disabled with a specific compile flag, for example -Werror=maybe-uninitialized.
The warning emitted by the compiler shows the flag for disabling it.

To causes that flag to be used in the build of GNU APL (i.e. to suppress
the warning) you need to run ./configure again with the flag appended to
the CXXFLAGS. For example:

CXXFLAGS=-Werror=maybe-uninitialized ./configure

Note that the CXXFLAGS are not .configure arguments (which appear on the right
of ./configure) but set a shell variable CXXFLAGS which is considered by
.configure (see INSTALL).

The bogus warnings reported so far follow...

-----------------------------------------------------------------------------
Platform: Fedora 32, gcc 10.0.1

Shape.hh:133:18: error: ‘shape_Z.Shape::rho[<unknown>]’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
  133 |         if (rho[r])   { volume /= rho[r];  rho[r] = sh;  volume *= rho[r]; }
      |             ~~~~~^

Suppress this (and other warnings) with:

CXXFLAGS="-Wno-maybe-uninitialized -Wno-class-memaccess" ./configure
-----------------------------------------------------------------------------
