patch 8.0.0497: arabic support is not fully tested
Problem: Arabic support is not fully tested.
Solution: Add more tests for the untested functions. Comment out
unreachable code.
diff --git a/src/arabic.c b/src/arabic.c
index cb43b80..9bc1669 100644
--- a/src/arabic.c
+++ b/src/arabic.c
@@ -24,7 +24,9 @@
static int chg_c_a2i(int cur_c);
static int chg_c_a2m(int cur_c);
static int chg_c_a2f(int cur_c);
+#if 0
static int chg_c_i2m(int cur_c);
+#endif
static int chg_c_f2m(int cur_c);
static int chg_c_laa2i(int hid_c);
static int chg_c_laa2f(int hid_c);
@@ -418,7 +420,10 @@
/*
* Change shape - from Initial to Medial
+ * This code is unreachable, because for the relevant characters ARABIC_CHAR()
+ * is FALSE;
*/
+#if 0
static int
chg_c_i2m(int cur_c)
{
@@ -450,6 +455,7 @@
}
return 0;
}
+#endif
/*
@@ -608,7 +614,11 @@
else if (!shape_c || A_is_f(shape_c) || A_is_s(shape_c) || prev_laa)
curr_c = A_is_valid(next_c) ? chg_c_a2i(c) : chg_c_a2s(c);
else if (A_is_valid(next_c))
+#if 0
curr_c = A_is_iso(c) ? chg_c_a2m(c) : chg_c_i2m(c);
+#else
+ curr_c = A_is_iso(c) ? chg_c_a2m(c) : 0;
+#endif
else if (A_is_valid(prev_c))
curr_c = chg_c_a2f(c);
else