nv50,nvc0: share the format table code
[mesa.git] / src / glsl / ir_function_detect_recursion.cpp
index 44a1cd0b950be726ad741e9690f6482ecff7abf5..890bc455f440253e676b90aff339d32ca6d61fb0 100644 (file)
 #include "glsl_parser_extras.h"
 #include "linker.h"
 #include "program/hash_table.h"
+#include "program.h"
 
 struct call_node : public exec_node {
    class function *func;
@@ -288,6 +289,8 @@ emit_errors_unlinked(const void *key, void *data, void *closure)
    function *f = (function *) data;
    YYLTYPE loc;
 
+   (void) key;
+
    char *proto = prototype_string(f->sig->return_type,
                                  f->sig->function_name(),
                                  &f->sig->parameters);
@@ -307,13 +310,13 @@ emit_errors_linked(const void *key, void *data, void *closure)
       (struct gl_shader_program *) closure;
    function *f = (function *) data;
 
+   (void) key;
+
    char *proto = prototype_string(f->sig->return_type,
                                  f->sig->function_name(),
                                  &f->sig->parameters);
 
-   linker_error_printf(prog,
-                      "function `%s' has static recursion.\n",
-                      proto);
+   linker_error(prog, "function `%s' has static recursion.\n", proto);
    ralloc_free(proto);
    prog->LinkStatus = false;
 }