From 8e697ab07f127d7e1a881a7032834a3115764f62 Mon Sep 17 00:00:00 2001 From: fennecdjay Date: Thu, 13 Jun 2019 22:23:54 +0200 Subject: [PATCH] :art:Remove \t --- ast | 2 +- src/arg.c | 20 ++++++++++---------- src/emit/emit.c | 2 +- src/lib/import.c | 8 ++++---- src/lib/opfunc.c | 2 +- src/parse/check.c | 12 ++++++------ src/parse/did_you_mean.c | 4 ++-- src/vm/vm.c | 4 ++-- 8 files changed, 27 insertions(+), 27 deletions(-) diff --git a/ast b/ast index ebe247e4..595dd5ed 160000 --- a/ast +++ b/ast @@ -1 +1 @@ -Subproject commit ebe247e43e6e2cddb6fc46ad63843405b3006bcb +Subproject commit 595dd5edbd94984c3b2eebc352d38476472f1a93 diff --git a/src/arg.c b/src/arg.c index cff9b59c..4a06f7d2 100644 --- a/src/arg.c +++ b/src/arg.c @@ -45,16 +45,16 @@ ANN void arg_release(Arg* arg) { static const char usage[] = "usage: Gwion \n" -"\t-h\t : this help\n" -"\t-k\t : show compilation flags\n" -"\t-c\t : load config\n" -"\t-p\t : add a plugin directory\n" -"\t-s\t : set samplerate\n" -"\t-i\t : set input channel number\n" -"\t-o\t : set output channel number\n" -"\t-d\t : set driver (and arguments)\n" -"\t-z\t : set memoization limit\n" -"\t-m\t : load module (and arguments)\n"; +" -h : this help\n" +" -k : show compilation flags\n" +" -c : load config\n" +" -p : add a plugin directory\n" +" -s : set samplerate\n" +" -i : set input channel number\n" +" -o : set output channel number\n" +" -d : set driver (and arguments)\n" +" -z : set memoization limit\n" +" -m : load module (and arguments)\n"; ANN static void config_parse(Arg* arg, const m_str name); diff --git a/src/emit/emit.c b/src/emit/emit.c index 5b91666d..8a556196 100644 --- a/src/emit/emit.c +++ b/src/emit/emit.c @@ -500,7 +500,7 @@ ANN static m_bool prim_gack(const Emitter emit, const Exp_Primary* primary) { } while((e = e->next)); if(emit_exp(emit, exp, 0) < 0) { free_vector(emit->gwion->mp, v); - ERR_B(exp->pos, "\t... in 'gack' expression.") + ERR_B(exp->pos, " ... in 'gack' expression.") } const Instr instr = emit_add_instr(emit, Gack); instr->m_val = offset; diff --git a/src/lib/import.c b/src/lib/import.c index 647982f2..3f6efaf8 100644 --- a/src/lib/import.c +++ b/src/lib/import.c @@ -300,7 +300,7 @@ ANN m_int gwi_item_ini(const Gwi gwi, const restrict m_str type, const restrict DL_Var* v = &gwi->var; memset(v, 0, sizeof(DL_Var)); if(!(v->t.xid = str2list(gwi->gwion->env, type, &v->array_depth))) - GWI_ERR_B("\t...\tduring var import '%s.%s'.", gwi->gwion->env->class_def->name, name) + GWI_ERR_B(" ... during var import '%s.%s'.", gwi->gwion->env->class_def->name, name) v->var.xid = insert_symbol(gwi->gwion->st, name); return GW_OK; } @@ -392,7 +392,7 @@ ANN static Arg_List make_dll_arg_list(const Gwi gwi, DL_Func * dl_fun) { if(!(type_decl = str2decl(env, arg->type, &array_depth))) { if(arg_list) free_arg_list(env->gwion->mp, arg_list); - GWI_ERR_O("\t...\tat argument '%i'", i + 1) + GWI_ERR_O(" ... at argument '%i'", i + 1) } if((type_path2 = str2list(env, arg->name, &array_depth2))) free_id_list(env->gwion->mp, type_path2); @@ -432,7 +432,7 @@ ANN static Func_Def make_dll_as_fun(const Gwi gwi, DL_Func * dl_fun, ae_flag fla flag |= ae_flag_builtin; Type_Decl* type_decl = import_td(gwi, dl_fun->type); if(!type_decl) - GWI_ERR_O("\t...\tduring @ function import '%s' (type).", dl_fun->name) + GWI_ERR_O(" ... during @ function import '%s' (type).", dl_fun->name) const m_str name = dl_fun->name; const Arg_List arg_list = make_dll_arg_list(gwi, dl_fun); const Func_Def func_def = new_func_def(mp, new_func_base(mp, type_decl, insert_symbol(gwi->gwion->st, name), arg_list), @@ -529,7 +529,7 @@ ANN static Stmt import_fptr(const Gwi gwi, DL_Func* dl_fun, ae_flag flag) { flag |= ae_flag_builtin; if(!(type_path = str2list(env, dl_fun->type, &array_depth)) || !(type_decl = new_type_decl(env->gwion->mp, type_path, 0))) - GWI_ERR_O("\t...\tduring fptr import '%s' (type).", dl_fun->name); + GWI_ERR_O(" ... during fptr import '%s' (type).", dl_fun->name); struct Func_Base_ *base = new_func_base(env->gwion->mp, type_decl, insert_symbol(env->gwion->st, dl_fun->name), args); return new_stmt_fptr(env->gwion->mp, base, flag); } diff --git a/src/lib/opfunc.c b/src/lib/opfunc.c index 5c27028e..6c3f6f2a 100644 --- a/src/lib/opfunc.c +++ b/src/lib/opfunc.c @@ -29,7 +29,7 @@ OP_CHECK(opck_const_rhs) { const Exp_Binary* bin = (Exp_Binary*)data; if(bin->rhs->meta != ae_meta_var) ERR_N(exp_self(bin)->pos, "cannot assign '%s' on types '%s' and '%s'.\n" - "\t...\t(reason: --- right-side operand is %s.)", + " ... (reason: --- right-side operand is %s.)", op2str(bin->op), bin->lhs->type->name, bin->rhs->type->name, access(bin->rhs->meta)) return bin->rhs->type; diff --git a/src/parse/check.c b/src/parse/check.c index 3e0cfa2a..c07cf452 100644 --- a/src/parse/check.c +++ b/src/parse/check.c @@ -528,7 +528,7 @@ ANN Func find_template_match(const Env env, const Value value, const Exp_Call* e } ANN static void print_current_args(Exp e) { - gw_err("and not\n\t"); + gw_err("and not\n "); do gw_err(" \033[32m%s\033[0m", e->type->name); while((e = e->next) && gw_err(",")); gw_err("\n"); @@ -544,12 +544,12 @@ ANN2(1) static void* function_alternative(const Env env, const Type f, const Exp env_err(env, pos, "argument type(s) do not match for function. should be :"); Func up = f->e->d.func; do { - gw_err("(%s)\t", up->name); + gw_err("(%s) ", up->name); const Arg_List e = up->def->base->args; e ? print_arg(e) : (void)gw_err("\033[32mvoid\033[0m"); gw_err("\n"); } while((up = up->next)); - args ? print_current_args(args) : (void)gw_err("and not:\n\t\033[32mvoid\033[0m\n"); + args ? print_current_args(args) : (void)gw_err("and not:\n \033[32mvoid\033[0m\n"); return NULL; } @@ -572,7 +572,7 @@ ANN static Func get_template_func(const Env env, const Exp_Call* func, const Val assert(exp_self(func)); ERR_O(exp_self(func)->pos, "function is template. automatic type guess not fully implemented yet.\n" - "\tplease provide template types. eg: ''") + " please provide template types. eg: ''") } ANN static Type check_exp_call_template(const Env env, const Exp_Call *exp) { @@ -1042,7 +1042,7 @@ ANN static m_bool check_signature_match(const Env env, const Func_Def fdef, cons const m_str f_name = s_name(fdef->base->xid); ERR_B(td_pos(fdef->base->td), "function '%s.%s' ressembles '%s.%s' but cannot override...\n" - "\t...(reason: '%s.%s' is declared as 'static')", + " ...(reason: '%s.%s' is declared as 'static')", c_name, f_name, p_name, c_name, GET_FLAG(fdef, static) ? c_name : p_name, f_name) } @@ -1109,7 +1109,7 @@ ANN static m_bool check_func_def_override(const Env env, const Func_Def fdef) { if(override && override->owner_class && isa(override->type, t_function) < 0) ERR_B(fdef->pos, "function name '%s' conflicts with previously defined value...\n" - "\tfrom super class '%s'...", + " from super class '%s'...", s_name(fdef->base->xid), override->owner_class->name) } if(func->value_ref->offset && (!fdef->base->tmpl || !fdef->base->tmpl->base)) diff --git a/src/parse/did_you_mean.c b/src/parse/did_you_mean.c index eb4fa609..aacc629c 100644 --- a/src/parse/did_you_mean.c +++ b/src/parse/did_you_mean.c @@ -55,7 +55,7 @@ ANN void did_you_mean_nspc(Nspc nspc, const char* name) { do ressembles(&v, nspc, name); while((nspc = nspc->parent)); for(m_uint i = 0; i < vector_size(&v); ++i) - gw_err("\t(did you mean '%s'?)\n", (m_str)vector_at(&v, i)); + gw_err(" (did you mean '%s'?)\n", (m_str)vector_at(&v, i)); vector_release(&v); } @@ -66,7 +66,7 @@ ANN void did_you_mean_type(Type type, const char* name) { do ressembles(&v, t->nspc, name); while((t = t->e->parent) && t->nspc); for(m_uint i = 0; i < vector_size(&v); ++i) - gw_err("\t(did you mean '%s'?)\n", (m_str)vector_at(&v, i)); + gw_err(" (did you mean '%s'?)\n", (m_str)vector_at(&v, i)); did_you_mean_nspc(type->nspc, name); vector_release(&v); } diff --git a/src/vm/vm.c b/src/vm/vm.c index 7e9d13cc..e50854f3 100644 --- a/src/vm/vm.c +++ b/src/vm/vm.c @@ -664,8 +664,8 @@ arrayaccess: { const m_int idx = *(m_int*)(reg + SZ_INT * instr->m_val); if(idx < 0 || (m_uint)idx >= m_vector_size(ARRAY(a.obj))) { - gw_err("\t... at index [%" INT_F "]\n", idx); - gw_err("\t... at dimension [%" INT_F "]\n", instr->m_val); + gw_err(" ... at index [%" INT_F "]\n", idx); + gw_err(" ... at dimension [%" INT_F "]\n", instr->m_val); shred->code = code; shred->mem = mem; exception(shred, "ArrayOutofBounds"); -- 2.43.0