diff options
Diffstat (limited to 'src/glsl/pp/sl_pp_macro.c')
-rw-r--r-- | src/glsl/pp/sl_pp_macro.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/glsl/pp/sl_pp_macro.c b/src/glsl/pp/sl_pp_macro.c index bacd468964c..b6214f66edc 100644 --- a/src/glsl/pp/sl_pp_macro.c +++ b/src/glsl/pp/sl_pp_macro.c @@ -131,14 +131,14 @@ sl_pp_macro_expand(struct sl_pp_context *context, macro_name = input[*pi].data.identifier; macro_str = sl_pp_context_cstr(context, macro_name); - /* TODO: Having the following built-ins hardcoded is a bit lame. */ if (!strcmp(macro_str, "__LINE__")) { - if (!mute && _out_number(context, state, 1)) { + if (!mute && _out_number(context, state, context->line)) { return -1; } (*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)) { return -1; |