diff options
author | Paul Berry <[email protected]> | 2013-12-17 12:13:11 -0800 |
---|---|---|
committer | Paul Berry <[email protected]> | 2013-12-30 11:21:08 -0800 |
commit | 26707abe5635e99814603a0f4895865e977cf267 (patch) | |
tree | be2b80723c8fef82c7cb50f0f290ee3927eb79b5 /src/mesa/drivers | |
parent | f425d56ba41382be04366d011536ee78a03a2f33 (diff) |
Rename overloads of _mesa_glsl_shader_target_name().
Previously, _mesa_glsl_shader_target_name() had an overload for GLenum
and an overload for the gl_shader_type enum, each of which behaved
differently. However, since GLenum is a synonym for unsigned int, and
unsigned ints are often used in place of gl_shader_type (e.g. in loop
indices), there was a big risk of calling the wrong overload by
mistake. This patch gives the two overloads different names so that
it's always clear which one we mean to call.
Reviewed-by: Brian Paul <[email protected]>
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_shader.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_shader.cpp b/src/mesa/drivers/dri/i965/brw_shader.cpp index 6f0ace8932c..3f59c804ca5 100644 --- a/src/mesa/drivers/dri/i965/brw_shader.cpp +++ b/src/mesa/drivers/dri/i965/brw_shader.cpp @@ -261,7 +261,7 @@ brw_link_shader(struct gl_context *ctx, struct gl_shader_program *shProg) if (ctx->Shader.Flags & GLSL_DUMP) { printf("\n"); printf("GLSL IR for linked %s program %d:\n", - _mesa_glsl_shader_target_name(shader->base.Type), shProg->Name); + _mesa_shader_enum_to_string(shader->base.Type), shProg->Name); _mesa_print_ir(shader->base.ir, NULL); printf("\n"); } @@ -274,7 +274,7 @@ brw_link_shader(struct gl_context *ctx, struct gl_shader_program *shProg) continue; printf("GLSL %s shader %d source for linked program %d:\n", - _mesa_glsl_shader_target_name(sh->Type), + _mesa_shader_enum_to_string(sh->Type), i, shProg->Name); printf("%s", sh->Source); |