Mercurial > vim
changeset 26964:5de60e0d65fa v8.2.4011
patch 8.2.4011: test fails because of changed error number
Commit: https://github.com/vim/vim/commit/bb8cac56d9c398a2b546d9c81c15e8c3d8fd811e
Author: Bram Moolenaar <Bram@vim.org>
Date: Wed Jan 5 18:16:53 2022 +0000
patch 8.2.4011: test fails because of changed error number
Problem: Test fails because of changed error number.
Solution: Restore old duplicate error message.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Wed, 05 Jan 2022 19:30:04 +0100 |
parents | da59984f3903 |
children | 76601978e211 |
files | src/errors.h src/match.c src/version.c |
diffstat | 3 files changed, 7 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/src/errors.h +++ b/src/errors.h @@ -1861,14 +1861,15 @@ EXTERN char e_spellfilemising_autocomman #endif EXTERN char e_id_is_reserved_for_match_nr[] INIT(= N_("E798: ID is reserved for \":match\": %d")); -// E799 unused +EXTERN char e_invalid_id_nr_must_be_greater_than_or_equal_to_one_1[] + INIT(= N_("E799: Invalid ID: %d (must be greater than or equal to 1)")); #ifndef FEAT_ARABIC EXTERN char e_arabic_cannot_be_used_not_enabled_at_compile_time[] INIT(= N_("E800: Arabic cannot be used: Not enabled at compile time\n")); #endif EXTERN char e_id_already_taken_nr[] INIT(= N_("E801: ID already taken: %d")); -EXTERN char e_invalid_id_nr_must_be_greater_than_or_equal_to_one[] +EXTERN char e_invalid_id_nr_must_be_greater_than_or_equal_to_one_2[] INIT(= N_("E802: Invalid ID: %d (must be greater than or equal to 1)")); EXTERN char e_id_not_found_nr[] INIT(= N_("E803: ID not found: %d"));
--- a/src/match.c +++ b/src/match.c @@ -45,7 +45,7 @@ match_add( return -1; if (id < -1 || id == 0) { - semsg(_(e_invalid_id_nr_must_be_greater_than_or_equal_to_one), id); + semsg(_(e_invalid_id_nr_must_be_greater_than_or_equal_to_one_1), id); return -1; } if (id != -1) @@ -233,7 +233,7 @@ match_delete(win_T *wp, int id, int perr if (id < 1) { if (perr == TRUE) - semsg(_(e_invalid_id_nr_must_be_greater_than_or_equal_to_one), id); + semsg(_(e_invalid_id_nr_must_be_greater_than_or_equal_to_one_2), id); return -1; } while (cur != NULL && cur->id != id)