mesa: Use unreachable instead of assert in check_valid_to_render
authorIan Romanick <ian.d.romanick@intel.com>
Tue, 11 Nov 2014 10:20:49 +0000 (10:20 +0000)
committerIan Romanick <ian.d.romanick@intel.com>
Tue, 2 Dec 2014 20:16:28 +0000 (12:16 -0800)
This is generally the prefered style these days.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/main/api_validate.c

index 181a61de999b8d71d60030769d6b0b6accd1a8bd..304d576d9b8bb050894d938bf975211db2eb0e1b 100644 (file)
@@ -113,7 +113,7 @@ check_valid_to_render(struct gl_context *ctx, const char *function)
       break;
 
    default:
-      assert(!"Invalid API value in check_valid_to_render()");
+      unreachable("Invalid API value in check_valid_to_render()");
    }
 
    return GL_TRUE;