summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2013-09-19 20:06:35 -0700
committerEric Anholt <eric@anholt.net>2013-09-23 12:45:22 -0700
commit669b88eb12496dd5f1ba933a56c8311624245639 (patch)
treeb29a0c0119cf31b0e540894236a77bbb41ada9a3 /src/mesa
parent673129e0b936b1c748e988d3f74f3efaab9e5693 (diff)
downloadexternal_mesa3d-669b88eb12496dd5f1ba933a56c8311624245639.zip
external_mesa3d-669b88eb12496dd5f1ba933a56c8311624245639.tar.gz
external_mesa3d-669b88eb12496dd5f1ba933a56c8311624245639.tar.bz2
mesa: Convert some runtime asserts to static asserts.
Noticed while grepping through the code for something else. v2: Don't convert really-runtime asserts to static asserts. Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Ian Romanick <ian.d.romanick@.intel.com>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/program/program.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/program/program.c b/src/mesa/program/program.c
index 2529c13..3a1eb73 100644
--- a/src/mesa/program/program.c
+++ b/src/mesa/program/program.c
@@ -72,10 +72,10 @@ _mesa_init_program(struct gl_context *ctx)
ASSERT(ctx->Const.FragmentProgram.MaxAddressOffset <= (1 << INST_INDEX_BITS));
/* If this fails, increase prog_instruction::TexSrcUnit size */
- ASSERT(MAX_TEXTURE_UNITS <= (1 << 5));
+ STATIC_ASSERT(MAX_TEXTURE_UNITS <= (1 << 5));
/* If this fails, increase prog_instruction::TexSrcTarget size */
- ASSERT(NUM_TEXTURE_TARGETS <= (1 << 4));
+ STATIC_ASSERT(NUM_TEXTURE_TARGETS <= (1 << 4));
ctx->Program.ErrorPos = -1;
ctx->Program.ErrorString = _mesa_strdup("");