aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/glsl/ir_reader.cpp
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2013-09-10 09:01:25 +0200
committermarha <marha@users.sourceforge.net>2013-09-10 09:01:25 +0200
commit889d7dd8e94a5538f388cc619115bf5c0b6fc0b7 (patch)
treebdda17693281525be9d48886acf2dc89ac4c66b4 /mesalib/src/glsl/ir_reader.cpp
parent2414a1de3cc17f438219f8f2a58b530d33e99a5e (diff)
downloadvcxsrv-889d7dd8e94a5538f388cc619115bf5c0b6fc0b7.tar.gz
vcxsrv-889d7dd8e94a5538f388cc619115bf5c0b6fc0b7.tar.bz2
vcxsrv-889d7dd8e94a5538f388cc619115bf5c0b6fc0b7.zip
fontconfig libX11 libXmu libxcb mesa xserver git update 10 Sep 2013
xserver commit 47ff382d1fce25a8b097d45b79489e891f1f1228 libxcb commit f1405d9fe4a6ddcae24585ba254389a4c4f4c8c9 libX11 commit cb107760df33ffc8630677e66e2e50aa37950a5c libXmu commit 2539e539eafdac88177c8ee30b043c5d52f017e4 fontconfig commit a61e145304da86c8c35b137493bbd8fd5dd1e7f5 mesa commit 395b9410860371a64d6b5f2d50679f29eb41729e
Diffstat (limited to 'mesalib/src/glsl/ir_reader.cpp')
-rw-r--r--mesalib/src/glsl/ir_reader.cpp18
1 files changed, 14 insertions, 4 deletions
diff --git a/mesalib/src/glsl/ir_reader.cpp b/mesalib/src/glsl/ir_reader.cpp
index f263fe810..ec35b682e 100644
--- a/mesalib/src/glsl/ir_reader.cpp
+++ b/mesalib/src/glsl/ir_reader.cpp
@@ -211,6 +211,12 @@ ir_reader::read_function(s_expression *expr, bool skip_body)
return added ? f : NULL;
}
+static bool
+always_available(const _mesa_glsl_parse_state *)
+{
+ return true;
+}
+
void
ir_reader::read_function_sig(ir_function *f, s_expression *expr, bool skip_body)
{
@@ -248,11 +254,15 @@ ir_reader::read_function_sig(ir_function *f, s_expression *expr, bool skip_body)
hir_parameters.push_tail(var);
}
- ir_function_signature *sig = f->exact_matching_signature(&hir_parameters);
+ ir_function_signature *sig =
+ f->exact_matching_signature(state, &hir_parameters);
if (sig == NULL && skip_body) {
/* If scanning for prototypes, generate a new signature. */
- sig = new(mem_ctx) ir_function_signature(return_type);
- sig->is_builtin = true;
+ /* ir_reader doesn't know what languages support a given built-in, so
+ * just say that they're always available. For now, other mechanisms
+ * guarantee the right built-ins are available.
+ */
+ sig = new(mem_ctx) ir_function_signature(return_type, always_available);
f->add_signature(sig);
} else if (sig != NULL) {
const char *badvar = sig->qualifiers_match(&hir_parameters);
@@ -659,7 +669,7 @@ ir_reader::read_call(s_expression *expr)
return NULL;
}
- ir_function_signature *callee = f->matching_signature(&parameters);
+ ir_function_signature *callee = f->matching_signature(state, &parameters);
if (callee == NULL) {
ir_read_error(expr, "couldn't find matching signature for function "
"%s", name->value());