patch 8.1.1145: compiler warning for unused function

Problem:    Compiler warning for unused function. (Tony Mechelynck)
Solution:   Add #ifdef.
diff --git a/src/option.c b/src/option.c
index b0fad01..ba12fd4 100644
--- a/src/option.c
+++ b/src/option.c
@@ -6030,6 +6030,7 @@
     return valid_name(val, ".-_");
 }
 
+#if defined(FEAT_SPELL) || defined(PROTO)
 /*
  * Return TRUE if "val" is a valid 'spellang' value.
  */
@@ -6052,6 +6053,7 @@
 	    return FALSE;
     return TRUE;
 }
+#endif
 
 /*
  * Handle string options that need some action to perform when changed.