aboutsummaryrefslogtreecommitdiffstats
path: root/src/glsl/glsl_symbol_table.cpp
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2010-11-05 06:08:45 -0700
committerEric Anholt <[email protected]>2010-11-29 17:08:27 -0800
commite8f5ebf313da3ce33ccbbcf9b72946853035fbdd (patch)
tree8709b84f862b9919410d82b4a384403e4dfa9c2c /src/glsl/glsl_symbol_table.cpp
parent2927b6c21202fd0f9a661665e0093e7193c5df6e (diff)
glsl: Make the symbol table's add_function just use the function's name.
Diffstat (limited to 'src/glsl/glsl_symbol_table.cpp')
-rw-r--r--src/glsl/glsl_symbol_table.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/glsl/glsl_symbol_table.cpp b/src/glsl/glsl_symbol_table.cpp
index e9bf89b951d..3b384d875ae 100644
--- a/src/glsl/glsl_symbol_table.cpp
+++ b/src/glsl/glsl_symbol_table.cpp
@@ -121,18 +121,18 @@ bool glsl_symbol_table::add_type(const char *name, const glsl_type *t)
return _mesa_symbol_table_add_symbol(table, -1, name, entry) == 0;
}
-bool glsl_symbol_table::add_function(const char *name, ir_function *f)
+bool glsl_symbol_table::add_function(ir_function *f)
{
- if (this->language_version == 110 && name_declared_this_scope(name)) {
+ if (this->language_version == 110 && name_declared_this_scope(f->name)) {
/* In 1.10, functions and variables have separate namespaces. */
- symbol_table_entry *existing = get_entry(name);
+ symbol_table_entry *existing = get_entry(f->name);
if ((existing->f == NULL) && (existing->t == NULL)) {
existing->f = f;
return true;
}
}
symbol_table_entry *entry = new(mem_ctx) symbol_table_entry(f);
- return _mesa_symbol_table_add_symbol(table, -1, name, entry) == 0;
+ return _mesa_symbol_table_add_symbol(table, -1, f->name, entry) == 0;
}
ir_variable *glsl_symbol_table::get_variable(const char *name)