patch 8.2.4038: various code not used when features are disabled
Problem: Various code not used when features are disabled.
Solution: Add #ifdefs. (Dominique Pellé, closes #9491)
diff --git a/src/message.c b/src/message.c
index 81c0f47..17c541f 100644
--- a/src/message.c
+++ b/src/message.c
@@ -876,6 +876,7 @@
siemsg(_(e_internal_error_str), where);
}
+#if defined(FEAT_EVAL) || defined(PROTO)
/*
* Like internal_error() but do not call abort(), to avoid tests using
* test_unknown() and test_void() causing Vim to exit.
@@ -885,6 +886,7 @@
{
semsg(_(e_internal_error_str), where);
}
+#endif
// emsg3() and emsgn() are in misc2.c to avoid warnings for the prototypes.
@@ -894,6 +896,7 @@
semsg(_(e_invalid_register_name_str), transchar(name));
}
+#if defined(FEAT_EVAL) || defined(PROTO)
/*
* Give an error message which contains %s for "name[len]".
*/
@@ -905,6 +908,7 @@
semsg(msg, copy == NULL ? "NULL" : (char *)copy);
vim_free(copy);
}
+#endif
/*
* Like msg(), but truncate to a single line if p_shm contains 't', or when