Re: [Mesa-dev] [PATCH 11/30] mesa: Change redundant code into loops in shaderapi.c.

2014-01-10 Thread Paul Berry
On 9 January 2014 20:03, Chris Forbes wrote: > This is a slightly odd construction (although copied from the existing > code): > > > + if ((shProg == NULL) || (shProg->_LinkedShaders[stage] == NULL)) > > +shProg = NULL; > You're right. This would be much better as: if ((shProg != NUL

Re: [Mesa-dev] [PATCH 11/30] mesa: Change redundant code into loops in shaderapi.c.

2014-01-09 Thread Chris Forbes
This is a slightly odd construction (although copied from the existing code): > + if ((shProg == NULL) || (shProg->_LinkedShaders[stage] == NULL)) > +shProg = NULL; ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.

[Mesa-dev] [PATCH 11/30] mesa: Change redundant code into loops in shaderapi.c.

2014-01-09 Thread Paul Berry
This is possible now that ctx->Shader.CurrentProgram is an array. --- src/mesa/main/shaderapi.c | 39 +-- 1 file changed, 9 insertions(+), 30 deletions(-) diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c index d57748c..61ac0e3 100644 --- a/src