diff options
author | Ian Romanick <ian.d.romanick@intel.com> | 2010-03-19 11:57:24 -0700 |
---|---|---|
committer | Ian Romanick <ian.d.romanick@intel.com> | 2010-03-19 11:57:24 -0700 |
commit | 8bde4cec6b189564b1f2d58514bd7e7a4b40f714 (patch) | |
tree | 6c4bd932f35b52cc8948255e4100b43478833483 /ir_variable.cpp | |
parent | 82de85e264383553dc3c3f827c3b3259355b1006 (diff) |
Use glsl_symbol_table instead of using _mesa_symbol_table directly
Diffstat (limited to 'ir_variable.cpp')
-rw-r--r-- | ir_variable.cpp | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/ir_variable.cpp b/ir_variable.cpp index e7cb43f..283842c 100644 --- a/ir_variable.cpp +++ b/ir_variable.cpp @@ -22,7 +22,7 @@ */ #include "glsl_parser_extras.h" -#include "symbol_table.h" +#include "glsl_symbol_table.h" #include "ir.h" #include "builtin_variables.h" @@ -32,13 +32,12 @@ static void add_builtin_variable(const builtin_variable *proto, exec_list *instructions, - struct _mesa_symbol_table *symtab) + glsl_symbol_table *symtab) { /* Create a new variable declaration from the description supplied by * the caller. */ - const glsl_type *const type = (glsl_type *) - _mesa_symbol_table_find_symbol(symtab, 0, proto->type); + const glsl_type *const type = symtab->get_type(proto->type); assert(type != NULL); @@ -54,13 +53,13 @@ add_builtin_variable(const builtin_variable *proto, exec_list *instructions, */ instructions->push_tail(var); - _mesa_symbol_table_add_symbol(symtab, 0, var->name, var); + symtab->add_variable(var->name, var); } static void generate_110_vs_variables(exec_list *instructions, - struct _mesa_symbol_table *symtab) + glsl_symbol_table *symtab) { for (unsigned i = 0; i < Elements(builtin_core_vs_variables); i++) { add_builtin_variable(& builtin_core_vs_variables[i], @@ -83,7 +82,7 @@ generate_110_vs_variables(exec_list *instructions, static void generate_120_vs_variables(exec_list *instructions, - struct _mesa_symbol_table *symtab) + glsl_symbol_table *symtab) { /* GLSL version 1.20 did not add any built-in variables in the vertex * shader. @@ -94,7 +93,7 @@ generate_120_vs_variables(exec_list *instructions, static void generate_130_vs_variables(exec_list *instructions, - struct _mesa_symbol_table *symtab) + glsl_symbol_table *symtab) { generate_120_vs_variables(instructions, symtab); |