aboutsummaryrefslogtreecommitdiff
path: root/src/check_expr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/check_expr.cpp')
-rw-r--r--src/check_expr.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp
index 7d8e0f829..b893b3a00 100644
--- a/src/check_expr.cpp
+++ b/src/check_expr.cpp
@@ -8164,8 +8164,12 @@ gb_internal ExprKind check_basic_directive_expr(CheckerContext *c, Operand *o, A
o->type = t_untyped_string;
o->value = exact_value_string(file);
} else if (name == "line") {
+ i32 line = bd->token.pos.line;
+ if (build_context.obfuscate_source_code_locations) {
+ line = obfuscate_i32(line);
+ }
o->type = t_untyped_integer;
- o->value = exact_value_i64(bd->token.pos.line);
+ o->value = exact_value_i64(line);
} else if (name == "procedure") {
if (c->curr_proc_decl == nullptr) {
error(node, "#procedure may only be used within procedures");