From 92a14fc1266894a958b0329fd2267c510f1ec1ac Mon Sep 17 00:00:00 2001 From: fennecdjay Date: Tue, 15 Oct 2019 13:31:26 +0200 Subject: [PATCH] :art: Improve scan0_sym --- src/parse/scan0.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/parse/scan0.c b/src/parse/scan0.c index 1102900d..e9695144 100644 --- a/src/parse/scan0.c +++ b/src/parse/scan0.c @@ -191,8 +191,8 @@ ANN m_bool scan0_type_def(const Env env, const Type_Def tdef) { ANN static Symbol scan0_sym(const Env env, const m_str name, const loc_t pos) { const size_t line_len = num_digit(pos->first_line); const size_t col_len = num_digit(pos->first_column); - char c[strlen(env->curr->name) + line_len + col_len + strlen(name) + 5]; - sprintf(c, "@%s:%s:%u:%u", name, env->curr->name, + char c[strlen(env->curr->name) + strlen(env->name) + line_len + col_len + strlen(name) + 6]; + sprintf(c, "@%s:%s:%s:%u:%u", name, env->name, env->curr->name, pos->first_line, pos->first_column); return insert_symbol(c); } -- 2.43.0