From: fennecdjay Date: Sun, 7 Jul 2019 21:18:49 +0000 (+0200) Subject: :fire: Remove find_typeof X-Git-Tag: nightly~2348^2~28 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=568b6a6a431af25405106fc3496a3f8c6408b617;p=gwion.git :fire: Remove find_typeof --- diff --git a/src/oo/env_utils.c b/src/oo/env_utils.c index d41ba904..df445cfd 100644 --- a/src/oo/env_utils.c +++ b/src/oo/env_utils.c @@ -38,21 +38,7 @@ ANN m_bool env_storage(const Env env, ae_flag flag, const loc_t pos) { return !(env->class_def && GET(flag, ae_flag_global)) ? GW_OK :GW_ERROR; } -ANN static Type find_typeof(const Env env, ID_List path) { - Value v = nspc_lookup_value1(env->curr, path->xid); // was lookup2 - Type t = actual_type(v->type); - path = path->next; - while(path) { - CHECK_OO((v = find_value(t, path->xid))) - t = v->type; - path = path->next; - } - return v->type; -} - ANN Type find_type(const Env env, ID_List path) { - if(path->ref) - return find_typeof(env, path); Type type = nspc_lookup_type1(env->curr, path->xid); CHECK_OO(type) Nspc nspc = type->nspc;