On 02/17/2014 08:21 AM, Juha-Pekka Heikkila wrote:
> Nested for loops running through tables against which they
> finally do an assert were ran also with optimized builds.

If you add a

#else
   (void) table;
#endif /* !defined(NDEBUG) */

then

Reviewed-by: Ian Romanick <ian.d.roman...@intel.com>

Otherwise it will add an unused parameter warning to my builds. :)

> Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikk...@gmail.com>
> ---
>  src/mesa/program/symbol_table.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/mesa/program/symbol_table.c b/src/mesa/program/symbol_table.c
> index 4f6f31f..64e24d8 100644
> --- a/src/mesa/program/symbol_table.c
> +++ b/src/mesa/program/symbol_table.c
> @@ -133,7 +133,7 @@ struct _mesa_symbol_table_iterator {
>  static void
>  check_symbol_table(struct _mesa_symbol_table *table)
>  {
> -#if 1
> +#if !defined(NDEBUG)
>      struct scope_level *scope;
>  
>      for (scope = table->current_scope; scope != NULL; scope = scope->next) {
> 

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to