glsl/tests: add GLSL_TYPE_UINT8, GLSL_TYPE_INT8 cases to switch statements
authorBrian Paul <brianp@vmware.com>
Thu, 26 Apr 2018 17:55:46 +0000 (11:55 -0600)
committerBrian Paul <brianp@vmware.com>
Tue, 1 May 2018 03:13:53 +0000 (21:13 -0600)
To silence warnings about unhandled switch values.
Untested otherwise.

v2: move the INT/UINT8 cases after the INT/UINT16 cases, per Eric.

Reviewed-by: Eric Anholt <eric@anholt.net>
src/compiler/glsl/tests/uniform_initializer_utils.cpp

index 0d7fa26752fd264c706dabaa4eea5c0c43ee8dc1..8c00c69b295e2e0f0db991428ab5d56d62be110f 100644 (file)
@@ -113,6 +113,8 @@ generate_data_element(void *mem_ctx, const glsl_type *type,
       case GLSL_TYPE_FLOAT16:
       case GLSL_TYPE_UINT16:
       case GLSL_TYPE_INT16:
+      case GLSL_TYPE_UINT8:
+      case GLSL_TYPE_INT8:
         ASSERT_TRUE(false);
         break;
       }
@@ -156,6 +158,8 @@ generate_data_element(void *mem_ctx, const glsl_type *type,
       case GLSL_TYPE_FLOAT16:
       case GLSL_TYPE_UINT16:
       case GLSL_TYPE_INT16:
+      case GLSL_TYPE_UINT8:
+      case GLSL_TYPE_INT8:
         ASSERT_TRUE(false);
         break;
       }
@@ -287,6 +291,8 @@ verify_data(gl_constant_value *storage, unsigned storage_array_size,
          case GLSL_TYPE_FLOAT16:
          case GLSL_TYPE_UINT16:
          case GLSL_TYPE_INT16:
+         case GLSL_TYPE_UINT8:
+         case GLSL_TYPE_INT8:
            ASSERT_TRUE(false);
            break;
         }