To: vim_dev@googlegroups.com Subject: Patch 9.0.1594 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 9.0.1594 Problem: Some internal error messages are translated. Solution: Consistently do not translate internal error messages. (closes #12459) Files: runtime/doc/message.txt, src/alloc.c, src/blowfish.c, src/errors.h, src/ex_docmd.c, src/getchar.c, src/gui_beval.c, src/gui_w32.c, src/if_cscope.c, src/if_tcl.c, src/map.c, src/memfile.c, src/memline.c, src/netbeans.c, src/option.c, src/optionstr.c, src/regexp.c, src/regexp_bt.c, src/regexp_nfa.c, src/textprop.c, src/undo.c *** ../vim-9.0.1593/runtime/doc/message.txt 2023-05-24 21:02:20.481162129 +0100 --- runtime/doc/message.txt 2023-05-31 16:57:13.060240870 +0100 *************** *** 76,84 **** LIST OF MESSAGES ! *E222* *E228* *E232* *E293* *E298* *E304* *E317* ! *E318* *E356* *E438* *E439* *E440* *E316* *E320* *E322* ! *E323* *E341* *E473* *E570* *E292* Add to read buffer ~ makemap: Illegal mode ~ Cannot create BalloonEval with both message and callback ~ --- 76,84 ---- LIST OF MESSAGES ! *E222* *E228* *E232* *E292* *E293* *E298* *E304* *E316* ! *E317* *E318* *E320* *E322* *E323* *E341* *E356* *E438* ! *E439* *E440* *E473* *E570* Add to read buffer ~ makemap: Illegal mode ~ Cannot create BalloonEval with both message and callback ~ *** ../vim-9.0.1593/src/alloc.c 2023-05-31 12:47:40.237318813 +0100 --- src/alloc.c 2023-05-31 16:57:13.060240870 +0100 *************** *** 226,232 **** { // Don't hide this message emsg_silent = 0; ! iemsg(_(e_internal_error_lalloc_zero)); return NULL; } --- 226,232 ---- { // Don't hide this message emsg_silent = 0; ! iemsg(e_internal_error_lalloc_zero); return NULL; } *** ../vim-9.0.1593/src/blowfish.c 2023-04-23 17:50:14.853935966 +0100 --- src/blowfish.c 2023-05-31 16:57:13.060240870 +0100 *************** *** 416,422 **** keylen = (int)STRLEN(key) / 2; if (keylen == 0) { ! iemsg(_(e_bf_key_init_called_with_empty_password)); return; } for (i = 0; i < keylen; i++) --- 416,422 ---- keylen = (int)STRLEN(key) / 2; if (keylen == 0) { ! iemsg(e_bf_key_init_called_with_empty_password); return; } for (i = 0; i < keylen; i++) *** ../vim-9.0.1593/src/errors.h 2023-05-27 13:40:03.388087776 +0100 --- src/errors.h 2023-05-31 16:57:13.060240870 +0100 *************** *** 98,104 **** EXTERN char e_no_write_since_last_change_add_bang_to_override[] INIT(= N_("E37: No write since last change (add ! to override)")); EXTERN char e_null_argument[] ! INIT(= N_("E38: Null argument")); #if defined(FEAT_DIGRAPHS) || defined(FEAT_TIMERS) || defined(FEAT_EVAL) EXTERN char e_number_expected[] INIT(= N_("E39: Number expected")); --- 98,104 ---- EXTERN char e_no_write_since_last_change_add_bang_to_override[] INIT(= N_("E37: No write since last change (add ! to override)")); EXTERN char e_null_argument[] ! INIT(= "E38: Null argument"); #if defined(FEAT_DIGRAPHS) || defined(FEAT_TIMERS) || defined(FEAT_EVAL) EXTERN char e_number_expected[] INIT(= N_("E39: Number expected")); *************** *** 114,122 **** INIT(= N_("E42: No Errors")); #endif EXTERN char e_damaged_match_string[] ! INIT(= N_("E43: Damaged match string")); EXTERN char e_corrupted_regexp_program[] ! INIT(= N_("E44: Corrupted regexp program")); EXTERN char e_readonly_option_is_set_add_bang_to_override[] INIT(= N_("E45: 'readonly' option is set (add ! to override)")); #ifdef FEAT_EVAL --- 114,122 ---- INIT(= N_("E42: No Errors")); #endif EXTERN char e_damaged_match_string[] ! INIT(= "E43: Damaged match string"); EXTERN char e_corrupted_regexp_program[] ! INIT(= "E44: Corrupted regexp program"); EXTERN char e_readonly_option_is_set_add_bang_to_override[] INIT(= N_("E45: 'readonly' option is set (add ! to override)")); #ifdef FEAT_EVAL *************** *** 526,532 **** INIT(= N_("E221: Marker cannot start with lower case letter")); #endif EXTERN char e_add_to_internal_buffer_that_was_already_read_from[] ! INIT(= N_("E222: Add to internal buffer that was already read from")); EXTERN char e_recursive_mapping[] INIT(= N_("E223: Recursive mapping")); EXTERN char e_global_abbreviation_already_exists_for_str[] --- 526,532 ---- INIT(= N_("E221: Marker cannot start with lower case letter")); #endif EXTERN char e_add_to_internal_buffer_that_was_already_read_from[] ! INIT(= "E222: Add to internal buffer that was already read from"); EXTERN char e_recursive_mapping[] INIT(= N_("E223: Recursive mapping")); EXTERN char e_global_abbreviation_already_exists_for_str[] *************** *** 538,544 **** EXTERN char e_mapping_already_exists_for_str[] INIT(= N_("E227: Mapping already exists for %s")); EXTERN char e_makemap_illegal_mode[] ! INIT(= N_("E228: makemap: Illegal mode")); #ifdef FEAT_GUI EXTERN char e_cannot_start_the_GUI[] INIT(= N_("E229: Cannot start the GUI")); --- 538,544 ---- EXTERN char e_mapping_already_exists_for_str[] INIT(= N_("E227: Mapping already exists for %s")); EXTERN char e_makemap_illegal_mode[] ! INIT(= "E228: makemap: Illegal mode"); #ifdef FEAT_GUI EXTERN char e_cannot_start_the_GUI[] INIT(= N_("E229: Cannot start the GUI")); *************** *** 548,554 **** INIT(= N_("E231: 'guifontwide' invalid")); #ifdef FEAT_BEVAL_GUI EXTERN char e_cannot_create_ballooneval_with_both_message_and_callback[] ! INIT(= N_("E232: Cannot create BalloonEval with both message and callback")); #endif # if defined(FEAT_GUI_GTK) || defined(FEAT_GUI_X11) EXTERN char e_cannot_open_display[] --- 548,554 ---- INIT(= N_("E231: 'guifontwide' invalid")); #ifdef FEAT_BEVAL_GUI EXTERN char e_cannot_create_ballooneval_with_both_message_and_callback[] ! INIT(= "E232: Cannot create BalloonEval with both message and callback"); #endif # if defined(FEAT_GUI_GTK) || defined(FEAT_GUI_X11) EXTERN char e_cannot_open_display[] *************** *** 708,714 **** #endif #ifdef FEAT_TCL EXTERN char e_tcl_fatal_error_reflist_corrupt_please_report_this[] ! INIT(= N_("E280: TCL FATAL ERROR: reflist corrupt!? Please report this to vim-dev@vim.org")); #endif // E281 unused EXTERN char e_cannot_read_from_str_2[] --- 708,714 ---- #endif #ifdef FEAT_TCL EXTERN char e_tcl_fatal_error_reflist_corrupt_please_report_this[] ! INIT(= "E280: TCL FATAL ERROR: reflist corrupt!? Please report this to vim-dev@vim.org"); #endif // E281 unused EXTERN char e_cannot_read_from_str_2[] *************** *** 739,747 **** #endif // E291 unused EXTERN char e_invalid_count_for_del_bytes_nr[] ! INIT(= N_("E292: Invalid count for del_bytes(): %ld")); EXTERN char e_block_was_not_locked[] ! INIT(= N_("E293: Block was not locked")); EXTERN char e_seek_error_in_swap_file_read[] INIT(= N_("E294: Seek error in swap file read")); EXTERN char e_read_error_in_swap_file[] --- 739,747 ---- #endif // E291 unused EXTERN char e_invalid_count_for_del_bytes_nr[] ! INIT(= "E292: Invalid count for del_bytes(): %ld"); EXTERN char e_block_was_not_locked[] ! INIT(= "E293: Block was not locked"); EXTERN char e_seek_error_in_swap_file_read[] INIT(= N_("E294: Seek error in swap file read")); EXTERN char e_read_error_in_swap_file[] *************** *** 751,761 **** EXTERN char e_write_error_in_swap_file[] INIT(= N_("E297: Write error in swap file")); EXTERN char e_didnt_get_block_nr_zero[] ! INIT(= N_("E298: Didn't get block nr 0?")); EXTERN char e_didnt_get_block_nr_one[] ! INIT(= N_("E298: Didn't get block nr 1?")); EXTERN char e_didnt_get_block_nr_two[] ! INIT(= N_("E298: Didn't get block nr 2?")); #ifdef FEAT_PERL EXTERN char e_perl_evaluation_forbidden_in_sandbox_without_safe_module[] INIT(= N_("E299: Perl evaluation forbidden in sandbox without the Safe module")); --- 751,761 ---- EXTERN char e_write_error_in_swap_file[] INIT(= N_("E297: Write error in swap file")); EXTERN char e_didnt_get_block_nr_zero[] ! INIT(= "E298: Didn't get block nr 0?"); EXTERN char e_didnt_get_block_nr_one[] ! INIT(= "E298: Didn't get block nr 1?"); EXTERN char e_didnt_get_block_nr_two[] ! INIT(= "E298: Didn't get block nr 2?"); #ifdef FEAT_PERL EXTERN char e_perl_evaluation_forbidden_in_sandbox_without_safe_module[] INIT(= N_("E299: Perl evaluation forbidden in sandbox without the Safe module")); *************** *** 769,775 **** EXTERN char e_unable_to_open_swap_file_for_str_recovery_impossible[] INIT(= N_("E303: Unable to open swap file for \"%s\", recovery impossible")); EXTERN char e_ml_upd_block0_didnt_get_block_zero[] ! INIT(= N_("E304: ml_upd_block0(): Didn't get block 0??")); EXTERN char e_no_swap_file_found_for_str[] INIT(= N_("E305: No swap file found for %s")); EXTERN char e_cannot_open_str[] --- 769,775 ---- EXTERN char e_unable_to_open_swap_file_for_str_recovery_impossible[] INIT(= N_("E303: Unable to open swap file for \"%s\", recovery impossible")); EXTERN char e_ml_upd_block0_didnt_get_block_zero[] ! INIT(= "E304: ml_upd_block0(): Didn't get block 0??"); EXTERN char e_no_swap_file_found_for_str[] INIT(= N_("E305: No swap file found for %s")); EXTERN char e_cannot_open_str[] *************** *** 791,819 **** EXTERN char e_preserve_failed[] INIT(= N_("E314: Preserve failed")); EXTERN char e_ml_get_invalid_lnum_nr[] ! INIT(= N_("E315: ml_get: Invalid lnum: %ld")); EXTERN char e_ml_get_cannot_find_line_nr_in_buffer_nr_str[] ! INIT(= N_("E316: ml_get: Cannot find line %ld in buffer %d %s")); EXTERN char e_pointer_block_id_wrong[] ! INIT(= N_("E317: Pointer block id wrong")); EXTERN char e_pointer_block_id_wrong_two[] ! INIT(= N_("E317: Pointer block id wrong 2")); EXTERN char e_pointer_block_id_wrong_three[] ! INIT(= N_("E317: Pointer block id wrong 3")); EXTERN char e_pointer_block_id_wrong_four[] ! INIT(= N_("E317: Pointer block id wrong 4")); EXTERN char e_updated_too_many_blocks[] ! INIT(= N_("E318: Updated too many blocks?")); EXTERN char e_sorry_command_is_not_available_in_this_version[] INIT(= N_("E319: Sorry, the command is not available in this version")); EXTERN char e_cannot_find_line_nr[] ! INIT(= N_("E320: Cannot find line %ld")); EXTERN char e_could_not_reload_str[] INIT(= N_("E321: Could not reload \"%s\"")); EXTERN char e_line_number_out_of_range_nr_past_the_end[] ! INIT(= N_("E322: Line number out of range: %ld past the end")); EXTERN char e_line_count_wrong_in_block_nr[] ! INIT(= N_("E323: Line count wrong in block %ld")); #ifdef FEAT_POSTSCRIPT EXTERN char e_cant_open_postscript_output_file[] INIT(= N_("E324: Can't open PostScript output file")); --- 791,819 ---- EXTERN char e_preserve_failed[] INIT(= N_("E314: Preserve failed")); EXTERN char e_ml_get_invalid_lnum_nr[] ! INIT(= "E315: ml_get: Invalid lnum: %ld"); EXTERN char e_ml_get_cannot_find_line_nr_in_buffer_nr_str[] ! INIT(= "E316: ml_get: Cannot find line %ld in buffer %d %s"); EXTERN char e_pointer_block_id_wrong[] ! INIT(= "E317: Pointer block id wrong"); EXTERN char e_pointer_block_id_wrong_two[] ! INIT(= "E317: Pointer block id wrong 2"); EXTERN char e_pointer_block_id_wrong_three[] ! INIT(= "E317: Pointer block id wrong 3"); EXTERN char e_pointer_block_id_wrong_four[] ! INIT(= "E317: Pointer block id wrong 4"); EXTERN char e_updated_too_many_blocks[] ! INIT(= "E318: Updated too many blocks?"); EXTERN char e_sorry_command_is_not_available_in_this_version[] INIT(= N_("E319: Sorry, the command is not available in this version")); EXTERN char e_cannot_find_line_nr[] ! INIT(= "E320: Cannot find line %ld"); EXTERN char e_could_not_reload_str[] INIT(= N_("E321: Could not reload \"%s\"")); EXTERN char e_line_number_out_of_range_nr_past_the_end[] ! INIT(= "E322: Line number out of range: %ld past the end"); EXTERN char e_line_count_wrong_in_block_nr[] ! INIT(= "E323: Line count wrong in block %ld"); #ifdef FEAT_POSTSCRIPT EXTERN char e_cant_open_postscript_output_file[] INIT(= N_("E324: Can't open PostScript output file")); *************** *** 855,861 **** EXTERN char e_internal_error_please_report_a_bug[] INIT(= N_("E340: Internal error; if you can reproduce please report a bug")); EXTERN char e_internal_error_lalloc_zero[] ! INIT(= N_("E341: Internal error: lalloc(0, )")); EXTERN char e_out_of_memory_allocating_nr_bytes[] INIT(= N_("E342: Out of memory! (allocating %lu bytes)")); EXTERN char e_invalid_path_number_must_be_at_end_of_path_or_be_followed_by_str[] --- 855,861 ---- EXTERN char e_internal_error_please_report_a_bug[] INIT(= N_("E340: Internal error; if you can reproduce please report a bug")); EXTERN char e_internal_error_lalloc_zero[] ! INIT(= "E341: Internal error: lalloc(0, )"); EXTERN char e_out_of_memory_allocating_nr_bytes[] INIT(= N_("E342: Out of memory! (allocating %lu bytes)")); EXTERN char e_invalid_path_number_must_be_at_end_of_path_or_be_followed_by_str[] *************** *** 887,893 **** EXTERN char e_unknown_option_str_2[] INIT(= N_("E355: Unknown option: %s")); EXTERN char e_get_varp_error[] ! INIT(= N_("E356: get_varp ERROR")); #ifdef FEAT_LANGMAP EXTERN char e_langmap_matching_character_missing_for_str[] INIT(= N_("E357: 'langmap': Matching character missing for %s")); --- 887,893 ---- EXTERN char e_unknown_option_str_2[] INIT(= N_("E355: Unknown option: %s")); EXTERN char e_get_varp_error[] ! INIT(= "E356: get_varp ERROR"); #ifdef FEAT_LANGMAP EXTERN char e_langmap_matching_character_missing_for_str[] INIT(= N_("E357: 'langmap': Matching character missing for %s")); *************** *** 1078,1088 **** EXTERN char e_terminal_capability_cm_required[] INIT(= N_("E437: Terminal capability \"cm\" required")); EXTERN char e_u_undo_line_numbers_wrong[] ! INIT(= N_("E438: u_undo: Line numbers wrong")); EXTERN char e_undo_list_corrupt[] ! INIT(= N_("E439: Undo list corrupt")); EXTERN char e_undo_line_missing[] ! INIT(= N_("E440: Undo line missing")); #ifdef FEAT_QUICKFIX EXTERN char e_there_is_no_preview_window[] INIT(= N_("E441: There is no preview window")); --- 1078,1088 ---- EXTERN char e_terminal_capability_cm_required[] INIT(= N_("E437: Terminal capability \"cm\" required")); EXTERN char e_u_undo_line_numbers_wrong[] ! INIT(= "E438: u_undo: Line numbers wrong"); EXTERN char e_undo_list_corrupt[] ! INIT(= "E439: Undo list corrupt"); EXTERN char e_undo_line_missing[] ! INIT(= "E440: Undo line missing"); #ifdef FEAT_QUICKFIX EXTERN char e_there_is_no_preview_window[] INIT(= N_("E441: There is no preview window")); *************** *** 1180,1186 **** EXTERN char e_command_failed[] INIT(= N_("E472: Command failed")); EXTERN char e_internal_error_in_regexp[] ! INIT(= N_("E473: Internal error in regexp")); EXTERN char e_invalid_argument[] INIT(= N_("E474: Invalid argument")); EXTERN char e_invalid_argument_str[] --- 1180,1186 ---- EXTERN char e_command_failed[] INIT(= N_("E472: Command failed")); EXTERN char e_internal_error_in_regexp[] ! INIT(= "E473: Internal error in regexp"); EXTERN char e_invalid_argument[] INIT(= N_("E474: Invalid argument")); EXTERN char e_invalid_argument_str[] *************** *** 1442,1448 **** INIT(= N_("E568: Duplicate cscope database not added")); // E569 unused EXTERN char e_fatal_error_in_cs_manage_matches[] ! INIT(= N_("E570: Fatal error in cs_manage_matches")); #endif #ifdef DYNAMIC_TCL EXTERN char e_sorry_this_command_is_disabled_tcl_library_could_not_be_loaded[] --- 1442,1448 ---- INIT(= N_("E568: Duplicate cscope database not added")); // E569 unused EXTERN char e_fatal_error_in_cs_manage_matches[] ! INIT(= "E570: Fatal error in cs_manage_matches"); #endif #ifdef DYNAMIC_TCL EXTERN char e_sorry_this_command_is_disabled_tcl_library_could_not_be_loaded[] *************** *** 2128,2134 **** INIT(= N_("E830: Undo number %ld not found")); #ifdef FEAT_CRYPT EXTERN char e_bf_key_init_called_with_empty_password[] ! INIT(= N_("E831: bf_key_init() called with empty password")); # ifdef FEAT_PERSISTENT_UNDO EXTERN char e_non_encrypted_file_has_encrypted_undo_file_str[] INIT(= N_("E832: Non-encrypted file has encrypted undo file: %s")); --- 2128,2134 ---- INIT(= N_("E830: Undo number %ld not found")); #ifdef FEAT_CRYPT EXTERN char e_bf_key_init_called_with_empty_password[] ! INIT(= "E831: bf_key_init() called with empty password"); # ifdef FEAT_PERSISTENT_UNDO EXTERN char e_non_encrypted_file_has_encrypted_undo_file_str[] INIT(= N_("E832: Non-encrypted file has encrypted undo file: %s")); *************** *** 2258,2264 **** EXTERN char e_nfa_regexp_not_enough_space_to_store_whole_nfa[] INIT(= N_("E876: (NFA regexp) Not enough space to store the whole NFA")); EXTERN char e_nfa_regexp_invalid_character_class_nr[] ! INIT(= N_("E877: (NFA regexp) Invalid character class: %d")); EXTERN char e_nfa_regexp_could_not_allocate_memory_for_branch_traversal[] INIT(= N_("E878: (NFA regexp) Could not allocate memory for branch traversal!")); #ifdef FEAT_SYN_HL --- 2258,2264 ---- EXTERN char e_nfa_regexp_not_enough_space_to_store_whole_nfa[] INIT(= N_("E876: (NFA regexp) Not enough space to store the whole NFA")); EXTERN char e_nfa_regexp_invalid_character_class_nr[] ! INIT(= "E877: (NFA regexp) Invalid character class: %d"); EXTERN char e_nfa_regexp_could_not_allocate_memory_for_branch_traversal[] INIT(= N_("E878: (NFA regexp) Could not allocate memory for branch traversal!")); #ifdef FEAT_SYN_HL *************** *** 2453,2459 **** # endif #endif EXTERN char e_command_table_needs_to_be_updated_run_make_cmdidxs[] ! INIT(= N_("E943: Command table needs to be updated, run 'make cmdidxs'")); EXTERN char e_reverse_range_in_character_class[] INIT(= N_("E944: Reverse range in character class")); EXTERN char e_range_too_large_in_character_class[] --- 2453,2459 ---- # endif #endif EXTERN char e_command_table_needs_to_be_updated_run_make_cmdidxs[] ! INIT(= "E943: Command table needs to be updated, run 'make cmdidxs'"); EXTERN char e_reverse_range_in_character_class[] INIT(= N_("E944: Reverse range in character class")); EXTERN char e_range_too_large_in_character_class[] *************** *** 2527,2533 **** #endif #ifdef FEAT_PROP_POPUP EXTERN char e_text_property_info_corrupted[] ! INIT(= N_("E967: Text property info corrupted")); EXTERN char e_need_at_least_one_of_id_or_type[] INIT(= N_("E968: Need at least one of 'id' or 'type'")); EXTERN char e_property_type_str_already_defined[] --- 2527,2533 ---- #endif #ifdef FEAT_PROP_POPUP EXTERN char e_text_property_info_corrupted[] ! INIT(= "E967: Text property info corrupted"); EXTERN char e_need_at_least_one_of_id_or_type[] INIT(= N_("E968: Need at least one of 'id' or 'type'")); EXTERN char e_property_type_str_already_defined[] *************** *** 3408,3414 **** INIT(= N_("E1335: Member is not writable: %s")); #endif EXTERN char e_internal_error_shortmess_too_long[] ! INIT(= N_("E1336: Internal error: shortmess too long")); #ifdef FEAT_EVAL EXTERN char e_class_member_not_found_str[] INIT(= N_("E1337: Class member not found: %s")); --- 3408,3414 ---- INIT(= N_("E1335: Member is not writable: %s")); #endif EXTERN char e_internal_error_shortmess_too_long[] ! INIT(= "E1336: Internal error: shortmess too long"); #ifdef FEAT_EVAL EXTERN char e_class_member_not_found_str[] INIT(= N_("E1337: Class member not found: %s")); *** ../vim-9.0.1593/src/ex_docmd.c 2023-05-24 21:02:20.485162125 +0100 --- src/ex_docmd.c 2023-05-31 16:57:13.064240865 +0100 *************** *** 3887,3893 **** if (command_count != (int)CMD_SIZE) { ! iemsg(_(e_command_table_needs_to_be_updated_run_make_cmdidxs)); getout(1); } --- 3887,3893 ---- if (command_count != (int)CMD_SIZE) { ! iemsg(e_command_table_needs_to_be_updated_run_make_cmdidxs); getout(1); } *** ../vim-9.0.1593/src/getchar.c 2023-05-07 17:39:19.803633900 +0100 --- src/getchar.c 2023-05-31 16:57:13.064240865 +0100 *************** *** 214,220 **** } else if (buf->bh_curr == NULL) // buffer has already been read { ! iemsg(_(e_add_to_internal_buffer_that_was_already_read_from)); return; } else if (buf->bh_index != 0) --- 214,220 ---- } else if (buf->bh_curr == NULL) // buffer has already been read { ! iemsg(e_add_to_internal_buffer_that_was_already_read_from); return; } else if (buf->bh_index != 0) *************** *** 1645,1652 **** } /* ! * Convert "c" plus "modifiers" to merge the effect of modifyOtherKeys into the ! * character. Also for when the Kitty key protocol is used. */ int merge_modifyOtherKeys(int c_arg, int *modifiers) --- 1645,1652 ---- } /* ! * Convert "c_arg" plus "modifiers" to merge the effect of modifyOtherKeys into ! * the character. Also for when the Kitty key protocol is used. */ int merge_modifyOtherKeys(int c_arg, int *modifiers) *************** *** 2480,2493 **** { if (put_string_in_typebuf(offset, 4, new_string, len, NULL, 0, NULL) == FAIL) ! return -1; } else { tp[2] = modifier; if (put_string_in_typebuf(offset + 3, 1, new_string, len, NULL, 0, NULL) == FAIL) ! return -1; } return len; } --- 2480,2493 ---- { if (put_string_in_typebuf(offset, 4, new_string, len, NULL, 0, NULL) == FAIL) ! return -1; } else { tp[2] = modifier; if (put_string_in_typebuf(offset + 3, 1, new_string, len, NULL, 0, NULL) == FAIL) ! return -1; } return len; } *************** *** 2798,2806 **** if (no_mapping == 0 || allow_keys != 0) { if ((typebuf.tb_maplen == 0 ! || (p_remap && typebuf.tb_noremap[ typebuf.tb_off] == RM_YES)) ! && !*timedout) keylen = check_termcode(max_mlen + 1, NULL, 0, NULL); else keylen = 0; --- 2798,2806 ---- if (no_mapping == 0 || allow_keys != 0) { if ((typebuf.tb_maplen == 0 ! || (p_remap && typebuf.tb_noremap[ typebuf.tb_off] == RM_YES)) ! && !*timedout) keylen = check_termcode(max_mlen + 1, NULL, 0, NULL); else keylen = 0; *************** *** 3282,3288 **** * get a character: 2. from the typeahead buffer */ c = typebuf.tb_buf[typebuf.tb_off]; ! if (advance) // remove chars from tb_buf { cmd_silent = (typebuf.tb_silent > 0); if (typebuf.tb_maplen > 0) --- 3282,3288 ---- * get a character: 2. from the typeahead buffer */ c = typebuf.tb_buf[typebuf.tb_off]; ! if (advance) // remove chars from typebuf { cmd_silent = (typebuf.tb_silent > 0); if (typebuf.tb_maplen > 0) *************** *** 3294,3301 **** gotchars(typebuf.tb_buf + typebuf.tb_off, 1); } ! KeyNoremap = typebuf.tb_noremap[ ! typebuf.tb_off]; del_typebuf(1, 0); } break; // got character, break the for loop --- 3294,3300 ---- gotchars(typebuf.tb_buf + typebuf.tb_off, 1); } ! KeyNoremap = typebuf.tb_noremap[typebuf.tb_off]; del_typebuf(1, 0); } break; // got character, break the for loop *** ../vim-9.0.1593/src/gui_beval.c 2023-04-22 22:54:28.049802336 +0100 --- src/gui_beval.c 2023-05-31 16:57:13.064240865 +0100 *************** *** 93,99 **** if (mesg != NULL && mesgCB != NULL) { ! iemsg(_(e_cannot_create_ballooneval_with_both_message_and_callback)); return NULL; } --- 93,99 ---- if (mesg != NULL && mesgCB != NULL) { ! iemsg(e_cannot_create_ballooneval_with_both_message_and_callback); return NULL; } *** ../vim-9.0.1593/src/gui_w32.c 2023-05-09 14:59:55.964088966 +0100 --- src/gui_w32.c 2023-05-31 16:57:13.064240865 +0100 *************** *** 8535,8541 **** if (mesg != NULL && mesgCB != NULL) { ! iemsg(_(e_cannot_create_ballooneval_with_both_message_and_callback)); return NULL; } --- 8535,8541 ---- if (mesg != NULL && mesgCB != NULL) { ! iemsg(e_cannot_create_ballooneval_with_both_message_and_callback); return NULL; } *** ../vim-9.0.1593/src/if_cscope.c 2023-01-22 21:14:32.617863616 +0000 --- src/if_cscope.c 2023-05-31 16:57:13.064240865 +0100 *************** *** 1723,1729 **** cs_print_tags_priv(mp, cp, cnt); break; default: // should not reach here ! iemsg(_(e_fatal_error_in_cs_manage_matches)); return NULL; } --- 1723,1729 ---- cs_print_tags_priv(mp, cp, cnt); break; default: // should not reach here ! iemsg(e_fatal_error_in_cs_manage_matches); return NULL; } *************** *** 2114,2127 **** int ch; char *buf = NULL; // buffer for possible error message from cscope int bufpos = 0; - char *cs_emsg; int maxlen; static char *eprompt = "Press the RETURN key to continue:"; int epromptlen = (int)strlen(eprompt); int n; - cs_emsg = _(e_cscope_error_str); // compute maximum allowed len for Cscope error message maxlen = (int)(IOSIZE - strlen(cs_emsg)); for (;;) --- 2114,2126 ---- int ch; char *buf = NULL; // buffer for possible error message from cscope int bufpos = 0; int maxlen; static char *eprompt = "Press the RETURN key to continue:"; int epromptlen = (int)strlen(eprompt); int n; // compute maximum allowed len for Cscope error message + char *cs_emsg = _(e_cscope_error_str); maxlen = (int)(IOSIZE - strlen(cs_emsg)); for (;;) *** ../vim-9.0.1593/src/if_tcl.c 2022-10-01 19:43:48.606494048 +0100 --- src/if_tcl.c 2023-05-31 16:57:13.068240857 +0100 *************** *** 1552,1558 **** reflist = reflist->next; } // This should never happen. Famous last word? ! iemsg(_(e_tcl_fatal_error_reflist_corrupt_please_report_this)); Tcl_SetResult(interp, _("cannot register callback command: buffer/window reference not found"), TCL_STATIC); return TCL_ERROR; } --- 1552,1558 ---- reflist = reflist->next; } // This should never happen. Famous last word? ! iemsg(e_tcl_fatal_error_reflist_corrupt_please_report_this); Tcl_SetResult(interp, _("cannot register callback command: buffer/window reference not found"), TCL_STATIC); return TCL_ERROR; } *** ../vim-9.0.1593/src/map.c 2023-04-15 13:17:22.879094522 +0100 --- src/map.c 2023-05-31 16:57:13.068240857 +0100 *************** *** 2043,2049 **** c1 = 't'; break; default: ! iemsg(_(e_makemap_illegal_mode)); return FAIL; } do // do this twice if c2 is set, 3 times with c3 --- 2043,2049 ---- c1 = 't'; break; default: ! iemsg(e_makemap_illegal_mode); return FAIL; } do // do this twice if c2 is set, 3 times with c3 *** ../vim-9.0.1593/src/memfile.c 2023-05-27 18:02:50.184062445 +0100 --- src/memfile.c 2023-05-31 16:57:13.068240857 +0100 *************** *** 478,484 **** flags = hp->bh_flags; if ((flags & BH_LOCKED) == 0) ! iemsg(_(e_block_was_not_locked)); flags &= ~BH_LOCKED; if (dirty) { --- 478,484 ---- flags = hp->bh_flags; if ((flags & BH_LOCKED) == 0) ! iemsg(e_block_was_not_locked); flags &= ~BH_LOCKED; if (dirty) { *** ../vim-9.0.1593/src/memline.c 2023-05-27 18:02:50.188062442 +0100 --- src/memline.c 2023-05-31 16:57:13.068240857 +0100 *************** *** 332,338 **** goto error; if (hp->bh_bnum != 0) { ! iemsg(_(e_didnt_get_block_nr_zero)); goto error; } b0p = (ZERO_BL *)(hp->bh_data); --- 332,338 ---- goto error; if (hp->bh_bnum != 0) { ! iemsg(e_didnt_get_block_nr_zero); goto error; } b0p = (ZERO_BL *)(hp->bh_data); *************** *** 382,388 **** goto error; if (hp->bh_bnum != 1) { ! iemsg(_(e_didnt_get_block_nr_one)); goto error; } pp = (PTR_BL *)(hp->bh_data); --- 382,388 ---- goto error; if (hp->bh_bnum != 1) { ! iemsg(e_didnt_get_block_nr_one); goto error; } pp = (PTR_BL *)(hp->bh_data); *************** *** 400,406 **** goto error; if (hp->bh_bnum != 2) { ! iemsg(_(e_didnt_get_block_nr_two)); goto error; } --- 400,406 ---- goto error; if (hp->bh_bnum != 2) { ! iemsg(e_didnt_get_block_nr_two); goto error; } *************** *** 974,980 **** b0p = (ZERO_BL *)(hp->bh_data); if (ml_check_b0_id(b0p) == FAIL) ! iemsg(_(e_ml_upd_block0_didnt_get_block_zero)); else { if (what == UB_FNAME) --- 974,980 ---- b0p = (ZERO_BL *)(hp->bh_data); if (ml_check_b0_id(b0p) == FAIL) ! iemsg(e_ml_upd_block0_didnt_get_block_zero); else { if (what == UB_FNAME) *************** *** 2678,2684 **** // Avoid giving this message for a recursive call, may happen when // the GUI redraws part of the text. ++recursive; ! siemsg(_(e_ml_get_invalid_lnum_nr), lnum); --recursive; } ml_flush_line(buf); --- 2678,2684 ---- // Avoid giving this message for a recursive call, may happen when // the GUI redraws part of the text. ++recursive; ! siemsg(e_ml_get_invalid_lnum_nr, lnum); --recursive; } ml_flush_line(buf); *************** *** 2725,2731 **** ++recursive; get_trans_bufname(buf); shorten_dir(NameBuff); ! siemsg(_(e_ml_get_cannot_find_line_nr_in_buffer_nr_str), lnum, buf->b_fnum, NameBuff); --recursive; } --- 2725,2731 ---- ++recursive; get_trans_bufname(buf); shorten_dir(NameBuff); ! siemsg(e_ml_get_cannot_find_line_nr_in_buffer_nr_str, lnum, buf->b_fnum, NameBuff); --recursive; } *************** *** 3219,3225 **** pp = (PTR_BL *)(hp->bh_data); // must be pointer block if (pp->pb_id != PTR_ID) { ! iemsg(_(e_pointer_block_id_wrong_three)); mf_put(mfp, hp, FALSE, FALSE); goto theend; } --- 3219,3225 ---- pp = (PTR_BL *)(hp->bh_data); // must be pointer block if (pp->pb_id != PTR_ID) { ! iemsg(e_pointer_block_id_wrong_three); mf_put(mfp, hp, FALSE, FALSE); goto theend; } *************** *** 3360,3366 **** */ if (stack_idx < 0) { ! iemsg(_(e_updated_too_many_blocks)); buf->b_ml.ml_stack_top = 0; // invalidate stack } } --- 3360,3366 ---- */ if (stack_idx < 0) { ! iemsg(e_updated_too_many_blocks); buf->b_ml.ml_stack_top = 0; // invalidate stack } } *************** *** 3820,3826 **** pp = (PTR_BL *)(hp->bh_data); // must be pointer block if (pp->pb_id != PTR_ID) { ! iemsg(_(e_pointer_block_id_wrong_four)); mf_put(mfp, hp, FALSE, FALSE); goto theend; } --- 3820,3826 ---- pp = (PTR_BL *)(hp->bh_data); // must be pointer block if (pp->pb_id != PTR_ID) { ! iemsg(e_pointer_block_id_wrong_four); mf_put(mfp, hp, FALSE, FALSE); goto theend; } *************** *** 4085,4091 **** hp = ml_find_line(buf, lnum, ML_FIND); if (hp == NULL) ! siemsg(_(e_cannot_find_line_nr), lnum); else { dp = (DATA_BL *)(hp->bh_data); --- 4085,4091 ---- hp = ml_find_line(buf, lnum, ML_FIND); if (hp == NULL) ! siemsg(e_cannot_find_line_nr, lnum); else { dp = (DATA_BL *)(hp->bh_data); *************** *** 4345,4351 **** pp = (PTR_BL *)(dp); // must be pointer block if (pp->pb_id != PTR_ID) { ! iemsg(_(e_pointer_block_id_wrong)); goto error_block; } --- 4345,4351 ---- pp = (PTR_BL *)(dp); // must be pointer block if (pp->pb_id != PTR_ID) { ! iemsg(e_pointer_block_id_wrong); goto error_block; } *************** *** 4390,4400 **** if (idx >= (int)pp->pb_count) // past the end: something wrong! { if (lnum > buf->b_ml.ml_line_count) ! siemsg(_(e_line_number_out_of_range_nr_past_the_end), lnum - buf->b_ml.ml_line_count); else ! siemsg(_(e_line_count_wrong_in_block_nr), bnum); goto error_block; } if (action == ML_DELETE) --- 4390,4400 ---- if (idx >= (int)pp->pb_count) // past the end: something wrong! { if (lnum > buf->b_ml.ml_line_count) ! siemsg(e_line_number_out_of_range_nr_past_the_end, lnum - buf->b_ml.ml_line_count); else ! siemsg(e_line_count_wrong_in_block_nr, bnum); goto error_block; } if (action == ML_DELETE) *************** *** 4487,4493 **** if (pp->pb_id != PTR_ID) { mf_put(mfp, hp, FALSE, FALSE); ! iemsg(_(e_pointer_block_id_wrong_two)); break; } pp->pb_pointer[ip->ip_index].pe_line_count += count; --- 4487,4493 ---- if (pp->pb_id != PTR_ID) { mf_put(mfp, hp, FALSE, FALSE); ! iemsg(e_pointer_block_id_wrong_two); break; } pp->pb_pointer[ip->ip_index].pe_line_count += count; *** ../vim-9.0.1593/src/netbeans.c 2023-05-20 16:39:03.337433572 +0100 --- src/netbeans.c 2023-05-31 16:57:13.068240857 +0100 *************** *** 518,524 **** * so I'm disabling it except for debugging. */ nbdebug(("nb_parse_cmd: Command error for \"%s\"\n", cmd)); ! emsg(_(e_bad_return_from_nb_do_cmd)); #endif } } --- 518,524 ---- * so I'm disabling it except for debugging. */ nbdebug(("nb_parse_cmd: Command error for \"%s\"\n", cmd)); ! emsg(e_bad_return_from_nb_do_cmd); #endif } } *** ../vim-9.0.1593/src/option.c 2023-05-06 22:21:07.247211940 +0100 --- src/option.c 2023-05-31 16:57:13.072240852 +0100 *************** *** 6532,6538 **** case PV_VSTS: return (char_u *)&(curbuf->b_p_vsts); case PV_VTS: return (char_u *)&(curbuf->b_p_vts); #endif ! default: iemsg(_(e_get_varp_error)); } // always return a valid pointer to avoid a crash! return (char_u *)&(curbuf->b_p_wm); --- 6532,6538 ---- case PV_VSTS: return (char_u *)&(curbuf->b_p_vsts); case PV_VTS: return (char_u *)&(curbuf->b_p_vts); #endif ! default: iemsg(e_get_varp_error); } // always return a valid pointer to avoid a crash! return (char_u *)&(curbuf->b_p_wm); *** ../vim-9.0.1593/src/optionstr.c 2023-05-11 15:02:52.231456894 +0100 --- src/optionstr.c 2023-05-31 16:57:13.072240852 +0100 *************** *** 379,385 **** if (idx < 0) // not found (should not happen) { semsg(_(e_internal_error_str), "set_string_option_direct()"); ! siemsg(_("For option %s"), name); return; } } --- 379,385 ---- if (idx < 0) // not found (should not happen) { semsg(_(e_internal_error_str), "set_string_option_direct()"); ! siemsg("For option %s", name); return; } } *** ../vim-9.0.1593/src/regexp.c 2023-05-09 21:15:26.397845247 +0100 --- src/regexp.c 2023-05-31 16:57:13.072240852 +0100 *************** *** 1370,1376 **** if (UCHARAT(((bt_regprog_T *)prog)->program) != REGMAGIC) { ! emsg(_(e_corrupted_regexp_program)); return TRUE; } return FALSE; --- 1370,1376 ---- if (UCHARAT(((bt_regprog_T *)prog)->program) != REGMAGIC) { ! iemsg(e_corrupted_regexp_program); return TRUE; } return FALSE; *************** *** 2022,2028 **** // Be paranoid... if ((source == NULL && expr == NULL) || dest == NULL) { ! emsg(_(e_null_argument)); return 0; } if (prog_magic_wrong()) --- 2022,2028 ---- // Be paranoid... if ((source == NULL && expr == NULL) || dest == NULL) { ! iemsg(e_null_argument); return 0; } if (prog_magic_wrong()) *************** *** 2389,2395 **** else if (*s == NUL) // we hit NUL. { if (copy) ! iemsg(_(e_damaged_match_string)); goto exit; } else --- 2389,2395 ---- else if (*s == NUL) // we hit NUL. { if (copy) ! iemsg(e_damaged_match_string); goto exit; } else *** ../vim-9.0.1593/src/regexp_bt.c 2023-01-22 21:14:32.617863616 +0000 --- src/regexp_bt.c 2023-05-31 16:57:13.072240852 +0100 *************** *** 1376,1382 **** if (one_exactly) EMSG_ONE_RET_NULL; // Supposed to be caught earlier. ! IEMSG_RET_NULL(_(e_internal_error_in_regexp)); // NOTREACHED case Magic('='): --- 1376,1382 ---- if (one_exactly) EMSG_ONE_RET_NULL; // Supposed to be caught earlier. ! IEMSG_RET_NULL(e_internal_error_in_regexp); // NOTREACHED case Magic('='): *************** *** 2477,2483 **** int flags; if (expr == NULL) ! IEMSG_RET_NULL(_(e_null_argument)); init_class_tab(); --- 2477,2483 ---- int flags; if (expr == NULL) ! IEMSG_RET_NULL(e_null_argument); init_class_tab(); *************** *** 3103,3109 **** break; default: // Oh dear. Called inappropriately. ! iemsg(_(e_corrupted_regexp_program)); #ifdef DEBUG printf("Called regrepeat with op code %d\n", OP(p)); #endif --- 3103,3109 ---- break; default: // Oh dear. Called inappropriately. ! iemsg(e_corrupted_regexp_program); #ifdef DEBUG printf("Called regrepeat with op code %d\n", OP(p)); #endif *************** *** 4327,4333 **** break; default: ! iemsg(_(e_corrupted_regexp_program)); #ifdef DEBUG printf("Illegal op code %d\n", op); #endif --- 4327,4333 ---- break; default: ! iemsg(e_corrupted_regexp_program); #ifdef DEBUG printf("Illegal op code %d\n", op); #endif *************** *** 4740,4746 **** { // We get here only if there's trouble -- normally "case END" is // the terminating point. ! iemsg(_(e_corrupted_regexp_program)); #ifdef DEBUG printf("Premature EOL\n"); #endif --- 4740,4746 ---- { // We get here only if there's trouble -- normally "case END" is // the terminating point. ! iemsg(e_corrupted_regexp_program); #ifdef DEBUG printf("Premature EOL\n"); #endif *************** *** 4889,4895 **** // Be paranoid... if (prog == NULL || line == NULL) { ! iemsg(_(e_null_argument)); goto theend; } --- 4889,4895 ---- // Be paranoid... if (prog == NULL || line == NULL) { ! iemsg(e_null_argument); goto theend; } *** ../vim-9.0.1593/src/regexp_nfa.c 2023-05-24 21:02:20.489162125 +0100 --- src/regexp_nfa.c 2023-05-31 16:57:13.072240852 +0100 *************** *** 5119,5125 **** default: // should not be here :P ! siemsg(_(e_nfa_regexp_invalid_character_class_nr), class); return FAIL; } return FAIL; --- 5119,5125 ---- default: // should not be here :P ! siemsg(e_nfa_regexp_invalid_character_class_nr, class); return FAIL; } return FAIL; *************** *** 7341,7347 **** // Be paranoid... if (prog == NULL || line == NULL) { ! iemsg(_(e_null_argument)); goto theend; } --- 7341,7347 ---- // Be paranoid... if (prog == NULL || line == NULL) { ! iemsg(e_null_argument); goto theend; } *** ../vim-9.0.1593/src/textprop.c 2023-03-07 17:45:07.192247897 +0000 --- src/textprop.c 2023-05-31 16:57:13.072240852 +0100 *************** *** 642,648 **** return 0; if (proplen % sizeof(textprop_T) != 0) { ! iemsg(_(e_text_property_info_corrupted)); return 0; } *props = text + textlen; --- 642,648 ---- return 0; if (proplen % sizeof(textprop_T) != 0) { ! iemsg(e_text_property_info_corrupted); return 0; } *props = text + textlen; *** ../vim-9.0.1593/src/undo.c 2023-01-26 11:58:39.606071598 +0000 --- src/undo.c 2023-05-31 16:57:13.072240852 +0100 *************** *** 2717,2723 **** || bot > curbuf->b_ml.ml_line_count + 1) { unblock_autocmds(); ! iemsg(_(e_u_undo_line_numbers_wrong)); changed(); // don't want UNCHANGED now return; } --- 2717,2723 ---- || bot > curbuf->b_ml.ml_line_count + 1) { unblock_autocmds(); ! iemsg(e_u_undo_line_numbers_wrong); changed(); // don't want UNCHANGED now return; } *************** *** 3307,3313 **** { if (curbuf->b_u_newhead == NULL || curbuf->b_u_newhead->uh_entry == NULL) { ! iemsg(_(e_undo_list_corrupt)); return NULL; } return curbuf->b_u_newhead->uh_entry; --- 3307,3313 ---- { if (curbuf->b_u_newhead == NULL || curbuf->b_u_newhead->uh_entry == NULL) { ! iemsg(e_undo_list_corrupt); return NULL; } return curbuf->b_u_newhead->uh_entry; *************** *** 3339,3345 **** uep->ue_bot = uep->ue_top + uep->ue_size + 1 + extra; if (uep->ue_bot < 1 || uep->ue_bot > curbuf->b_ml.ml_line_count) { ! iemsg(_(e_undo_line_missing)); uep->ue_bot = uep->ue_top + 1; // assume all lines deleted, will // get all the old lines back // without deleting the current --- 3339,3345 ---- uep->ue_bot = uep->ue_top + uep->ue_size + 1 + extra; if (uep->ue_bot < 1 || uep->ue_bot > curbuf->b_ml.ml_line_count) { ! iemsg(e_undo_line_missing); uep->ue_bot = uep->ue_top + 1; // assume all lines deleted, will // get all the old lines back // without deleting the current *** ../vim-9.0.1593/src/version.c 2023-05-31 12:47:40.237318813 +0100 --- src/version.c 2023-05-31 16:58:12.672151972 +0100 *************** *** 697,698 **** --- 697,700 ---- { /* Add new patch number below this line */ + /**/ + 1594, /**/ -- From "know your smileys": :-& Eating spaghetti /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// \\\ \\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///