summaryrefslogtreecommitdiffstats
path: root/src/glsl/pp/sl_pp_macro.c
diff options
context:
space:
mode:
authorMichal Krol <[email protected]>2009-09-04 15:27:08 +0200
committerMichal Krol <[email protected]>2009-09-07 10:12:10 +0200
commita64ba93aab6de7ee2ceb70f39cf2dbe794940c97 (patch)
treed576bc47c543fa6506cb49d506283b4e3e51ecf5 /src/glsl/pp/sl_pp_macro.c
parent2d2d6384448baae3c04eced3373d96907def4e13 (diff)
glsl: Handle file numbering.
Diffstat (limited to 'src/glsl/pp/sl_pp_macro.c')
-rw-r--r--src/glsl/pp/sl_pp_macro.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/glsl/pp/sl_pp_macro.c b/src/glsl/pp/sl_pp_macro.c
index b6214f66edc..d14c9825557 100644
--- a/src/glsl/pp/sl_pp_macro.c
+++ b/src/glsl/pp/sl_pp_macro.c
@@ -138,9 +138,8 @@ sl_pp_macro_expand(struct sl_pp_context *context,
(*pi)++;
return 0;
}
- /* TODO: Having the following built-ins hardcoded is a bit lame. */
if (!strcmp(macro_str, "__FILE__")) {
- if (!mute && _out_number(context, state, 0)) {
+ if (!mute && _out_number(context, state, context->file)) {
return -1;
}
(*pi)++;