summaryrefslogtreecommitdiff
path: root/src/errors.h
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-08-15 16:33:28 +0200
committerBram Moolenaar <Bram@vim.org>2020-08-15 16:33:28 +0200
commit451c2e3536a3cb77d07faf3cb2b834512e174351 (patch)
treec2dbbf67dc33787ea4e1aaa64baec99b77346ea2 /src/errors.h
parent53b29e4845857d76ca7df1ff2fd0e03c3eeb82e1 (diff)
downloadvim-git-451c2e3536a3cb77d07faf3cb2b834512e174351.tar.gz
patch 8.2.1460: error messages are spread outv8.2.1460
Problem: Error messages are spread out. Solution: Move more messages into errors.h.
Diffstat (limited to 'src/errors.h')
-rw-r--r--src/errors.h202
1 files changed, 200 insertions, 2 deletions
diff --git a/src/errors.h b/src/errors.h
index f61327600..6a2e50ee3 100644
--- a/src/errors.h
+++ b/src/errors.h
@@ -11,26 +11,224 @@
*/
#ifdef FEAT_EVAL
+EXTERN char e_undefined_variable_str[]
+ INIT(= N_("E121: Undefined variable: %s"));
+EXTERN char e_undefined_variable_char_str[]
+ INIT(= N_("E121: Undefined variable: %c:%s"));
+#endif
+EXTERN char e_invalid_command[]
+ INIT(= N_("E476: Invalid command"));
+#ifdef FEAT_EVAL
+EXTERN char e_invalid_command_str[]
+ INIT(= N_("E476: Invalid command: %s"));
+EXTERN char e_missing_let_str[]
+ INIT(= N_("E1100: Missing :let: %s"));
+EXTERN char e_variable_not_found_str[]
+ INIT(= N_("E1001: variable not found: %s"));
+EXTERN char e_syntax_error_at_str[]
+ INIT(= N_("E1002: Syntax error at %s"));
+EXTERN char e_missing_return_value[]
+ INIT(= N_("E1003: Missing return value"));
EXTERN char e_white_space_required_before_and_after[]
INIT(= N_("E1004: white space required before and after '%s'"));
+EXTERN char e_too_many_argument_types[]
+ INIT(= N_("E1005: Too many argument types"));
+EXTERN char e_str_is_used_as_argument[]
+ INIT(= N_("E1006: %s is used as an argument"));
+EXTERN char e_mandatory_argument_after_optional_argument[]
+ INIT(= N_("E1007: mandatory argument after optional argument"));
+EXTERN char e_missing_type[]
+ INIT(= N_("E1008: Missing <type>"));
+EXTERN char e_missing_gt_after_type[]
+ INIT(= N_("E1009: Missing > after type"));
+EXTERN char e_type_not_recognized_str[]
+ INIT(= N_("E1010: Type not recognized: %s"));
+EXTERN char e_name_too_long_str[]
+ INIT(= N_("E1011: name too long: %s"));
+EXTERN char e_type_mismatch_expected_str_but_got_str[]
+ INIT(= N_("E1012: type mismatch, expected %s but got %s"));
+EXTERN char e_argument_nr_type_mismatch_expected_str_but_got_str[]
+ INIT(= N_("E1013: argument %d: type mismatch, expected %s but got %s"));
+EXTERN char e_invalid_key_str[]
+ INIT(= N_("E1014: Invalid key: %s"));
+EXTERN char e_name_expected[]
+ INIT(= N_("E1015: Name expected: %s"));
EXTERN char e_cannot_declare_a_scope_variable[]
INIT(= N_("E1016: Cannot declare a %s variable: %s"));
EXTERN char e_cannot_declare_an_environment_variable[]
INIT(= N_("E1016: Cannot declare an environment variable: %s"));
+EXTERN char e_variable_already_declared[]
+ INIT(= N_("E1017: Variable already declared: %s"));
+EXTERN char e_cannot_assign_to_constant[]
+ INIT(= N_("E1018: Cannot assign to a constant: %s"));
+EXTERN char e_can_only_concatenate_to_string[]
+ INIT(= N_("E1019: Can only concatenate to string"));
+EXTERN char e_cannot_use_operator_on_new_variable[]
+ INIT(= N_("E1020: cannot use an operator on a new variable: %s"));
EXTERN char e_const_requires_a_value[]
INIT(= N_("E1021: const requires a value"));
EXTERN char e_type_or_initialization_required[]
INIT(= N_("E1022: type or initialization required"));
+// E1023 unused
+// E1024 unused
+EXTERN char e_using_rcurly_outside_if_block_scope[]
+ INIT(= N_("E1025: using } outside of a block scope"));
+EXTERN char e_missing_rcurly[]
+ INIT(= N_("E1026: Missing }"));
+EXTERN char e_missing_return_statement[]
+ INIT(= N_("E1027: Missing return statement"));
+EXTERN char e_compile_def_function_failed[]
+ INIT(= N_("E1028: compile_def_function failed"));
+EXTERN char e_expected_str_but_got_str[]
+ INIT(= N_("E1029: Expected %s but got %s"));
+EXTERN char e_using_string_as_number[]
+ INIT(= N_("E1030: Using a String as a Number"));
+EXTERN char e_cannot_use_void_value[]
+ INIT(= N_("E1031: Cannot use void value"));
+EXTERN char e_missing_catch_or_finally[]
+ INIT(= N_("E1032: missing :catch or :finally"));
+EXTERN char e_catch_unreachable_after_catch_all[]
+ INIT(= N_("E1033: catch unreachable after catch-all"));
+EXTERN char e_cannot_use_reserved_name[]
+ INIT(= N_("E1034: Cannot use reserved name %s"));
+EXTERN char e_percent_requires_number_arguments[]
+ INIT(= N_("E1035: % requires number arguments"));
+EXTERN char e_char_requires_number_or_float_arguments[]
+ INIT(= N_("E1036: %c requires number or float arguments"));
+EXTERN char e_cannot_use_str_with_str[]
+ INIT(= N_("E1037: Cannot use \"%s\" with %s"));
+EXTERN char e_vim9script_can_only_be_used_in_script[]
+ INIT(= N_("E1038: vim9script can only be used in a script"));
+EXTERN char e_vim9script_must_be_first_command_in_script[]
+ INIT(= N_("E1039: vim9script must be the first command in a script"));
+EXTERN char e_cannot_use_scriptversion_after_vim9script[]
+ INIT(= N_("E1040: Cannot use :scriptversion after :vim9script"));
+EXTERN char e_redefining_script_item_str[]
+ INIT(= N_("E1041: Redefining script item %s"));
+EXTERN char e_export_can_only_be_used_in_vim9script[]
+ INIT(= N_("E1042: export can only be used in vim9script"));
+EXTERN char e_invalid_command_after_export[]
+ INIT(= N_("E1043: Invalid command after :export"));
+EXTERN char e_export_with_invalid_argument[]
+ INIT(= N_("E1044: export with invalid argument"));
+EXTERN char e_missing_as_after_star[]
+ INIT(= N_("E1045: Missing \"as\" after *"));
+EXTERN char e_missing_comma_in_import[]
+ INIT(= N_("E1046: Missing comma in import"));
+EXTERN char e_syntax_error_in_import[]
+ INIT(= N_("E1047: syntax error in import"));
+EXTERN char e_item_not_found_in_script_str[]
+ INIT(= N_("E1048: Item not found in script: %s"));
+EXTERN char e_item_not_exported_in_script_str[]
+ INIT(= N_("E1049: Item not exported in script: %s"));
EXTERN char e_colon_required_before_a_range[]
INIT(= N_("E1050: Colon required before a range"));
+EXTERN char e_wrong_argument_type_for_plus[]
+ INIT(= N_("E1051: wrong argument type for +"));
+EXTERN char e_cannot_declare_an_option[]
+ INIT(= N_("E1052: Cannot declare an option: %s"));
+EXTERN char e_could_not_import_str[]
+ INIT(= N_("E1053: Could not import \"%s\""));
+EXTERN char e_variable_already_declared_in_script[]
+ INIT(= N_("E1054: Variable already declared in the script: %s"));
+EXTERN char e_missing_name_after_dots[]
+ INIT(= N_("E1055: Missing name after ..."));
+EXTERN char e_expected_type_str[]
+ INIT(= N_("E1056: expected a type: %s"));
+EXTERN char e_missing_enddef[]
+ INIT(= N_("E1057: Missing :enddef"));
+EXTERN char e_function_nesting_too_deep[]
+ INIT(= N_("E1058: function nesting too deep"));
+EXTERN char e_no_white_space_allowed_before_colon_str[]
+ INIT(= N_("E1059: No white space allowed before colon: %s"));
+EXTERN char e_expected_dot_after_name_str[]
+ INIT(= N_("E1060: expected dot after name: %s"));
+EXTERN char e_cannot_find_function_str[]
+ INIT(= N_("E1061: Cannot find function %s"));
+// E1062 unused
+EXTERN char e_type_mismatch_for_v_variable[]
+ INIT(= N_("E1063: type mismatch for v: variable"));
+// E1064 unused
+// E1065 unused
+EXTERN char e_cannot_declare_a_register[]
+ INIT(= N_("E1066: Cannot declare a register: %s"));
+EXTERN char e_separator_mismatch[]
+ INIT(= N_("E1067: Separator mismatch: %s"));
EXTERN char e_no_white_space_allowed_before[]
INIT(= N_("E1068: No white space allowed before '%s'"));
EXTERN char e_white_space_required_after[]
INIT(= N_("E1069: white space required after '%s'"));
+EXTERN char e_missing_from[]
+ INIT(= N_("E1070: Missing \"from\""));
+EXTERN char e_invalid_string_after_from[]
+ INIT(= N_("E1071: Invalid string after \"from\""));
+EXTERN char e_cannot_compare_str_with_str[]
+ INIT(= N_("E1072: Cannot compare %s with %s"));
EXTERN char e_name_already_defined[]
INIT(= N_("E1073: name already defined: %s"));
-EXTERN char e_list_dict_or_blob_required[]
- INIT(= N_("E1090: List, Dict or Blob required"));
+EXTERN char e_no_white_space_allowed_after_dot[]
+ INIT(= N_("E1074: no white space allowed after dot"));
+EXTERN char e_namespace_not_supported_str[]
+ INIT(= N_("E1075: Namespace not supported: %s"));
+EXTERN char e_this_vim_is_not_compiled_with_float_support[]
+ INIT(= N_("E1076: This Vim is not compiled with float support"));
+EXTERN char e_missing_argument_type_for_str[]
+ INIT(= N_("E1077: Missing argument type for %s"));
+// E1078 unused
+// E1079 unused
+// E1080 unused
+EXTERN char e_cannot_unlet_str[]
+ INIT(= N_("E1081: Cannot unlet %s"));
+EXTERN char e_cannot_use_namespaced_variable[]
+ INIT(= N_("E1082: Cannot use a namespaced variable: %s"));
+EXTERN char e_missing_backtick[]
+ INIT(= N_("E1083: missing backtick"));
+EXTERN char e_cannot_delete_vim9_script_function_str[]
+ INIT(= N_("E1084: Cannot delete Vim9 script function %s"));
+EXTERN char e_not_callable_type_str[]
+ INIT(= N_("E1085: Not a callable type: %s"));
+EXTERN char e_cannot_use_function_inside_def[]
+ INIT(= N_("E1086: Cannot use :function inside :def"));
+EXTERN char e_cannot_use_index_when_declaring_variable[]
+ INIT(= N_("E1087: cannot use an index when declaring a variable"));
+// E1088 unused
+EXTERN char e_unknown_variable_str[]
+ INIT(= N_("E1089: unknown variable: %s"));
+EXTERN char e_cannot_assign_to_argument[]
+ INIT(= N_("E1090: Cannot assign to argument %s"));
+EXTERN char e_function_is_not_compiled_str[]
+ INIT(= N_("E1091: Function is not compiled: %s"));
+EXTERN char e_cannot_use_list_for_declaration[]
+ INIT(= N_("E1092: Cannot use a list for a declaration"));
+EXTERN char e_expected_nr_items_but_got_nr[]
+ INIT(= N_("E1093: Expected %d items but got %d"));
+EXTERN char e_import_can_only_be_used_in_script[]
+ INIT(= N_("E1094: import can only be used in a script"));
+EXTERN char e_unreachable_code_after_return[]
+ INIT(= N_("E1095: Unreachable code after :return"));
+EXTERN char e_returning_value_in_function_without_return_type[]
+ INIT(= N_("E1096: Returning a value in a function without a return type"));
+EXTERN char e_line_incomplete[]
+ INIT(= N_("E1097: line incomplete"));
+// E1098 unused
+EXTERN char e_unknown_error_while_executing_str[]
+ INIT(= N_("E1099: Unknown error while executing %s"));
+EXTERN char e_cannot_declare_script_variable_in_function[]
+ INIT(= N_("E1101: Cannot declare a script variable in a function: %s"));
+EXTERN char e_lambda_function_not_found_str[]
+ INIT(= N_("E1102: lambda function not found: %s"));
EXTERN char e_dictionary_not_set[]
INIT(= N_("E1103: Dictionary not set"));
+EXTERN char e_missing_gt[]
+ INIT(= N_("E1104: Missing >"));
+EXTERN char e_cannot_convert_str_to_string[]
+ INIT(= N_("E1105: Cannot convert %s to string"));
+EXTERN char e_one_argument_too_many[]
+ INIT(= N_("E1106: one argument too many"));
+EXTERN char e_nr_arguments_too_many[]
+ INIT(= N_("E1106: %d arguments too many"));
+EXTERN char e_list_dict_or_blob_required[]
+ INIT(= N_("E1107: List, Dict or Blob required"));
+EXTERN char e_item_not_found_str[]
+ INIT(= N_("E1108: Item not found: %s"));
#endif