summaryrefslogtreecommitdiffstats
path: root/dimension
diff options
context:
space:
mode:
Diffstat (limited to 'dimension')
-rw-r--r--dimension/parse.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/dimension/parse.c b/dimension/parse.c
index ac74568..a4a4c43 100644
--- a/dimension/parse.c
+++ b/dimension/parse.c
@@ -809,7 +809,11 @@ dmnsn_eval(dmnsn_astnode astnode, dmnsn_symbol_table *symtable)
{
dmnsn_astnode *symbol = dmnsn_find_symbol(symtable, astnode.ptr);
if (symbol) {
- return dmnsn_eval(*symbol, symtable);
+ dmnsn_astnode id = *symbol;
+ id.filename = astnode.filename;
+ id.line = astnode.line;
+ id.col = astnode.col;
+ return dmnsn_eval(id, symtable);
} else {
dmnsn_diagnostic(astnode.filename, astnode.line, astnode.col,
"Unbound identifier '%s'", (const char *)astnode.ptr);