overte-JulianGro/libraries/gpu
Dale Glass ea36e7a239 Fix thousands of 'is too small to hold all values' warnings on Linux
When building with GCC, it generates 3020 warnings like this:

libraries/gpu/src/gpu/State.h:208:18: warning: ‘gpu::State::BlendFunction::destColor’
is too small to hold all values of ‘enum gpu::State::BlendArg’

This is because ‘enum gpu::State::BlendArg’ is declared as an enum
of uint16 size, and gpu::State::BlendFunction::destColor is a bit
field.

GCC correctly deduces that a 16 bit value won't always fit in a 4
bit field, and emits a warning.

The problem is that the amount is such that it floods the output and hides
other warnings.

Changing the 'enum foo : uint16' declarations to 'enum foo' stops gcc
from emitting the warning.

Making this change required the removal of a set of assertion checks. At least
empirically they seem unnecessary -- the interface compiles and runs fine.
2020-01-08 00:12:30 +01:00
..
src/gpu Fix thousands of 'is too small to hold all values' warnings on Linux 2020-01-08 00:12:30 +01:00
CMakeLists.txt Gpu Frame serialization 2019-01-23 13:21:34 -08:00