]>
Commit | Line | Data |
---|---|---|
3e524028 AG |
1 | To: vim-dev@vim.org |
2 | Subject: Patch 7.2.092 | |
3 | Fcc: outbox | |
4 | From: Bram Moolenaar <Bram@moolenaar.net> | |
5 | Mime-Version: 1.0 | |
6 | Content-Type: text/plain; charset=ISO-8859-1 | |
7 | Content-Transfer-Encoding: 8bit | |
8 | ------------ | |
9 | ||
10 | Patch 7.2.092 | |
11 | Problem: Some error messages are not translated. | |
12 | Solution: Add _() around the messages. (Dominique Pelle) | |
13 | Files: src/eval.c | |
14 | ||
15 | ||
16 | *** ../vim-7.2.091/src/eval.c Sun Dec 21 13:02:47 2008 | |
17 | --- src/eval.c Sat Jan 24 12:22:47 2009 | |
18 | *************** | |
19 | *** 7918,7926 **** | |
20 | else if (!aborting()) | |
21 | { | |
22 | if (argcount == MAX_FUNC_ARGS) | |
23 | ! emsg_funcname("E740: Too many arguments for function %s", name); | |
24 | else | |
25 | ! emsg_funcname("E116: Invalid arguments for function %s", name); | |
26 | } | |
27 | ||
28 | while (--argcount >= 0) | |
29 | --- 7918,7926 ---- | |
30 | else if (!aborting()) | |
31 | { | |
32 | if (argcount == MAX_FUNC_ARGS) | |
33 | ! emsg_funcname(N_("E740: Too many arguments for function %s"), name); | |
34 | else | |
35 | ! emsg_funcname(N_("E116: Invalid arguments for function %s"), name); | |
36 | } | |
37 | ||
38 | while (--argcount >= 0) | |
39 | *************** | |
40 | *** 8153,8158 **** | |
41 | --- 8153,8159 ---- | |
42 | ||
43 | /* | |
44 | * Give an error message with a function name. Handle <SNR> things. | |
45 | + * "ermsg" is to be passed without translation, use N_() instead of _(). | |
46 | */ | |
47 | static void | |
48 | emsg_funcname(ermsg, name) | |
49 | *************** | |
50 | *** 19867,19873 **** | |
51 | } | |
52 | } | |
53 | else | |
54 | ! emsg_funcname("E123: Undefined function: %s", name); | |
55 | } | |
56 | goto ret_free; | |
57 | } | |
58 | --- 19868,19874 ---- | |
59 | } | |
60 | } | |
61 | else | |
62 | ! emsg_funcname(N_("E123: Undefined function: %s"), name); | |
63 | } | |
64 | goto ret_free; | |
65 | } | |
66 | *************** | |
67 | *** 19911,19917 **** | |
68 | : eval_isnamec(arg[j]))) | |
69 | ++j; | |
70 | if (arg[j] != NUL) | |
71 | ! emsg_funcname(_(e_invarg2), arg); | |
72 | } | |
73 | } | |
74 | ||
75 | --- 19912,19918 ---- | |
76 | : eval_isnamec(arg[j]))) | |
77 | ++j; | |
78 | if (arg[j] != NUL) | |
79 | ! emsg_funcname(e_invarg2, arg); | |
80 | } | |
81 | } | |
82 | ||
83 | *************** | |
84 | *** 20183,20189 **** | |
85 | v = find_var(name, &ht); | |
86 | if (v != NULL && v->di_tv.v_type == VAR_FUNC) | |
87 | { | |
88 | ! emsg_funcname("E707: Function name conflicts with variable: %s", | |
89 | name); | |
90 | goto erret; | |
91 | } | |
92 | --- 20184,20190 ---- | |
93 | v = find_var(name, &ht); | |
94 | if (v != NULL && v->di_tv.v_type == VAR_FUNC) | |
95 | { | |
96 | ! emsg_funcname(N_("E707: Function name conflicts with variable: %s"), | |
97 | name); | |
98 | goto erret; | |
99 | } | |
100 | *************** | |
101 | *** 20198,20204 **** | |
102 | } | |
103 | if (fp->uf_calls > 0) | |
104 | { | |
105 | ! emsg_funcname("E127: Cannot redefine function %s: It is in use", | |
106 | name); | |
107 | goto erret; | |
108 | } | |
109 | --- 20199,20205 ---- | |
110 | } | |
111 | if (fp->uf_calls > 0) | |
112 | { | |
113 | ! emsg_funcname(N_("E127: Cannot redefine function %s: It is in use"), | |
114 | name); | |
115 | goto erret; | |
116 | } | |
117 | *************** | |
118 | *** 21477,21483 **** | |
119 | ||
120 | /* | |
121 | * Return TRUE if items in "fc" do not have "copyID". That means they are not | |
122 | ! * referenced from anywyere. | |
123 | */ | |
124 | static int | |
125 | can_free_funccal(fc, copyID) | |
126 | --- 21478,21484 ---- | |
127 | ||
128 | /* | |
129 | * Return TRUE if items in "fc" do not have "copyID". That means they are not | |
130 | ! * referenced from anywhere. | |
131 | */ | |
132 | static int | |
133 | can_free_funccal(fc, copyID) | |
134 | *** ../vim-7.2.091/src/version.c Wed Jan 28 16:03:51 2009 | |
135 | --- src/version.c Wed Jan 28 19:05:47 2009 | |
136 | *************** | |
137 | *** 678,679 **** | |
138 | --- 678,681 ---- | |
139 | { /* Add new patch number below this line */ | |
140 | + /**/ | |
141 | + 92, | |
142 | /**/ | |
143 | ||
144 | ||
145 | -- | |
146 | Now it is such a bizarrely improbable coincidence that anything as | |
147 | mind-bogglingly useful as the Babel fish could have evolved purely by chance | |
148 | that some thinkers have chosen to see it as a final and clinching proof of the | |
149 | NON-existence of God. | |
150 | The argument goes something like this: 'I refuse to prove that I exist,' says | |
151 | God, 'for proof denies faith, and without faith I am nothing.' | |
152 | 'But,' says Man, 'the Babel fish is a dead giveaway, isn't it? It could not | |
153 | have evolved by chance. It proves you exist, and so therefore, by your own | |
154 | arguments, you don't. QED.' | |
155 | 'Oh dear,' says God, 'I hadn't thought of that,' and promptly vanishes in a | |
156 | puff of logic. | |
157 | 'Oh, that was easy,' says Man, and for an encore goes on to prove that black | |
158 | is white and gets himself killed on the next pedestrian crossing. | |
159 | -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" | |
160 | ||
161 | /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ | |
162 | /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ | |
163 | \\\ download, build and distribute -- http://www.A-A-P.org /// | |
164 | \\\ help me help AIDS victims -- http://ICCF-Holland.org /// |