On Thu, Nov 29, 2012 at 10:24 PM, Henri Verbeet <hverbeet(a)gmail.com> wrote:
On 29 November 2012 17:04, Frédéric Delanoy
<frederic.delanoy(a)gmail.com> wrote:
case
WINED3D_TOP_BUMPENVMAP_LUMINANCE:
lum_map |= 1 << stage;
+ /* fall through */
case WINED3D_TOP_BUMPENVMAP:
bump_map |= 1 << stage;
+ /* fall through */
case WINED3D_TOP_BLEND_TEXTURE_ALPHA:
case WINED3D_TOP_BLEND_TEXTURE_ALPHA_PM:
tex_map |= 1 << stage;
I'm not opposed to these if they make it easier to find real bugs
inside the noise with Coverity, but I would also note that it should
be pretty obvious to anyone actually touching this code that the fall
through is intentional.
Indeed this case is pretty obvious, but it's not always the case in
other files, and IMHO the reader should know quickly what was the
intent of the programmer, hence the explicit "fall through" comment.
I'm currently running through the remaining "missing break" coverity
warning, so we can differentiate between real bugs and implicit
constructs.
Frédéric