From 1d7624edfdfe53cd9d8f82396e51d4fb1ad79d33 Mon Sep 17 00:00:00 2001 From: Vincenzo Palazzo Date: Fri, 8 Apr 2022 15:23:43 +0200 Subject: [PATCH] ast: improve V style Signed-off-by: Vincenzo Palazzo --- vlib/v/ast/types.v | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vlib/v/ast/types.v b/vlib/v/ast/types.v index c476e3e2f4..7bc360d1c8 100644 --- a/vlib/v/ast/types.v +++ b/vlib/v/ast/types.v @@ -1160,7 +1160,7 @@ fn (t Table) shorten_user_defined_typenames(originalname string, import_aliases // there is a []modul.name if res.contains('[]') { idx := res.index('.') or { -1 } - return res.substr(idx + 1, res.len) + return res[idx + 1..] } // types defined by the user // mod.submod.submod2.Type => submod2.Type