commit 29a33c3a314e669c58891066b0a1aa2bb5b879b3
parent 3c662b0b6ab07812e1468e51e0f3a6622721fc81
Author: Ed van Bruggen <edvb@uw.edu>
Date: Sat, 16 Jan 2021 00:01:56 -0800
Remove strlen function in replace for get len
Diffstat:
1 file changed, 0 insertions(+), 13 deletions(-)
diff --git a/tib/string.c b/tib/string.c
@@ -100,22 +100,9 @@ prim_Sym(Tsp st, Hash env, Val args)
return val_string(st, args, mk_sym);
}
-static Val
-prim_strlen(Tsp st, Hash env, Val args)
-{
- Val str;
- tsp_arg_num(args, "strlen", 1);
- str = car(args);
- if (!(str->t & (TSP_STR|TSP_SYM)))
- tsp_warnf("strlen: expected string or symbol, received %s",
- type_str(str->t));
- return mk_int(strlen(str->v.s));
-}
-
void
tib_env_string(Tsp st)
{
tsp_env_prim(Sym);
tsp_env_prim(Str);
- tsp_env_prim(strlen);
}