patch 9.0.1515: reverse() does not work for a String
Problem: reverse() does not work for a String.
Solution: Implement reverse() for a String. (Yegappan Lakshmanan,
closes #12179)
diff --git a/src/list.c b/src/list.c
index ca43526..7042965 100644
--- a/src/list.c
+++ b/src/list.c
@@ -2999,6 +2999,8 @@
if (argvars[0].v_type == VAR_BLOB)
blob_reverse(argvars[0].vval.v_blob, rettv);
+ else if (argvars[0].v_type == VAR_STRING)
+ string_reverse(argvars[0].vval.v_string, rettv);
else if (argvars[0].v_type != VAR_LIST)
semsg(_(e_argument_of_str_must_be_list_or_blob), "reverse()");
else