1 |
argrath |
1.1 |
|
2 |
|
|
=encoding utf8 |
3 |
|
|
|
4 |
|
|
=head1 NAME |
5 |
|
|
|
6 |
|
|
=begin original |
7 |
|
|
|
8 |
|
|
perl5160delta - what is new for perl v5.16.0 |
9 |
|
|
|
10 |
|
|
=end original |
11 |
|
|
|
12 |
argrath |
1.2 |
perl5160delta - perl v5.16.0 での変更点 |
13 |
argrath |
1.1 |
|
14 |
|
|
=head1 DESCRIPTION |
15 |
|
|
|
16 |
|
|
=begin original |
17 |
|
|
|
18 |
|
|
This document describes differences between the 5.14.0 release and |
19 |
|
|
the 5.16.0 release. |
20 |
|
|
|
21 |
|
|
=end original |
22 |
|
|
|
23 |
argrath |
1.2 |
この文書は 5.14.0 リリースと 5.16.0 リリースの変更点を記述しています。 |
24 |
argrath |
1.1 |
|
25 |
|
|
=begin original |
26 |
|
|
|
27 |
|
|
If you are upgrading from an earlier release such as 5.12.0, first read |
28 |
|
|
L<perl5140delta>, which describes differences between 5.12.0 and |
29 |
|
|
5.14.0. |
30 |
|
|
|
31 |
|
|
=end original |
32 |
|
|
|
33 |
argrath |
1.2 |
5.12.0 のような以前のリリースから更新する場合は、まず 5.12.0 と |
34 |
|
|
5.14.0 の違いについて記述している L<perl5140delta> を読んでください。 |
35 |
argrath |
1.1 |
|
36 |
argrath |
1.16 |
=begin original |
37 |
|
|
|
38 |
|
|
Some of the bug fixes in this release have been backported to subsequent |
39 |
|
|
releases of 5.14.x. Those are indicated with the 5.14.x version in |
40 |
|
|
parentheses. |
41 |
|
|
|
42 |
|
|
=end original |
43 |
|
|
|
44 |
|
|
Some of the bug fixes in this release have been backported to subsequent |
45 |
|
|
releases of 5.14.x. Those are indicated with the 5.14.x version in |
46 |
|
|
parentheses. |
47 |
|
|
(TBT) |
48 |
|
|
|
49 |
argrath |
1.1 |
=head1 Notice |
50 |
|
|
|
51 |
|
|
=begin original |
52 |
|
|
|
53 |
argrath |
1.16 |
With the release of Perl 5.16.0, the 5.12.x series of releases are now out of |
54 |
|
|
their support period. There may be future 5.12.x releases, but only in the |
55 |
|
|
event of a critical security issue. Users of Perl 5.12 or earlier should |
56 |
|
|
consider upgrading to a more recent release of Perl. |
57 |
argrath |
1.1 |
|
58 |
|
|
=end original |
59 |
|
|
|
60 |
argrath |
1.16 |
Perl 5.16.0 のリリースによって、5.12.x リリースシリーズはサポート期間が |
61 |
|
|
終了します。 |
62 |
|
|
将来 5.12.x リリースがあるかもしれませんが、それは重大なセキュリティ問題が |
63 |
|
|
あった場合のみです。 |
64 |
argrath |
1.6 |
Perl 5.12 以前のユーザーはより新しい Perl にアップグレードすることを |
65 |
|
|
検討するべきです。 |
66 |
argrath |
1.1 |
|
67 |
argrath |
1.16 |
=begin original |
68 |
|
|
|
69 |
|
|
This policy is described in greater detail in |
70 |
|
|
L<perlpolicy|perlpolicy/MAINTENANCE AND SUPPORT>. |
71 |
|
|
|
72 |
|
|
=end original |
73 |
|
|
|
74 |
|
|
このポリシーは L<perlpolicy|perlpolicy/MAINTENANCE AND SUPPORT> に |
75 |
|
|
より詳細に記述されています。 |
76 |
|
|
|
77 |
argrath |
1.1 |
=head1 Core Enhancements |
78 |
|
|
|
79 |
|
|
(コアの拡張) |
80 |
|
|
|
81 |
|
|
=head2 C<use I<VERSION>> |
82 |
|
|
|
83 |
|
|
=begin original |
84 |
|
|
|
85 |
|
|
As of this release, version declarations like C<use v5.16> now disable |
86 |
|
|
all features before enabling the new feature bundle. This means that |
87 |
|
|
the following holds true: |
88 |
|
|
|
89 |
|
|
=end original |
90 |
|
|
|
91 |
|
|
このリリース以降、C<use v5.16> のようなバージョン宣言は、新しい機能が |
92 |
|
|
有効になる前の全ての機能が無効になるようになりました。 |
93 |
|
|
これは、以下のようなものが真であることを意味します: |
94 |
|
|
|
95 |
|
|
use 5.016; |
96 |
|
|
# only 5.16 features enabled here |
97 |
|
|
use 5.014; |
98 |
|
|
# only 5.14 features enabled here (not 5.16) |
99 |
|
|
|
100 |
|
|
=begin original |
101 |
|
|
|
102 |
|
|
C<use v5.12> and higher continue to enable strict, but explicit C<use |
103 |
|
|
strict> and C<no strict> now override the version declaration, even |
104 |
|
|
when they come first: |
105 |
|
|
|
106 |
|
|
=end original |
107 |
|
|
|
108 |
|
|
C<use v5.12> 以上は strict を有効にするという機能ははそのままですが、 |
109 |
|
|
明示的な C<use strict> と C<no strict> は (先に現れても) バージョン定義を |
110 |
|
|
上書きするようになりました: |
111 |
|
|
|
112 |
|
|
no strict; |
113 |
|
|
use 5.012; |
114 |
|
|
# no strict here |
115 |
|
|
|
116 |
|
|
=begin original |
117 |
|
|
|
118 |
|
|
There is a new ":default" feature bundle that represents the set of |
119 |
|
|
features enabled before any version declaration or C<use feature> has |
120 |
|
|
been seen. Version declarations below 5.10 now enable the ":default" |
121 |
|
|
feature set. This does not actually change the behaviour of C<use |
122 |
|
|
v5.8>, because features added to the ":default" set are those that were |
123 |
|
|
traditionally enabled by default, before they could be turned off. |
124 |
|
|
|
125 |
|
|
=end original |
126 |
|
|
|
127 |
|
|
新しい ":default" 機能は、任意のバージョン定義や C<use feature> が |
128 |
|
|
現れる前に有効な機能の集合を表現します。 |
129 |
|
|
5.10 以前のバージョン宣言は ":default" 機能集合を有効にするように |
130 |
|
|
なりました。 |
131 |
|
|
これは実際には C<use v5.8> の振る舞いを変更しません; なぜなら |
132 |
|
|
":default" 集合は、機能を無効に出来るようになる前に伝統的にデフォルトで |
133 |
|
|
有効になっていたものだからです。 |
134 |
|
|
|
135 |
|
|
=begin original |
136 |
|
|
|
137 |
|
|
C<< no feature >> now resets to the default feature set. To disable all |
138 |
|
|
features (which is likely to be a pretty special-purpose request, since |
139 |
|
|
it presumably won't match any named set of semantics) you can now |
140 |
|
|
write C<< no feature ':all' >>. |
141 |
|
|
|
142 |
|
|
=end original |
143 |
|
|
|
144 |
|
|
C<< no feature >> はデフォルト機能集合をリセットするようになりました。 |
145 |
|
|
全ての機能を無効にする (これはかなり特殊な用途の要求です; なぜなら |
146 |
|
|
おそらく動作の全ての名前付き集合にマッチングしないからです) には、 |
147 |
|
|
C<< no feature ':all' >> と書けるようになります。 |
148 |
|
|
|
149 |
|
|
=begin original |
150 |
|
|
|
151 |
|
|
C<$[> is now disabled under C<use v5.16>. It is part of the default |
152 |
|
|
feature set and can be turned on or off explicitly with C<use feature |
153 |
|
|
'array_base'>. |
154 |
|
|
|
155 |
|
|
=end original |
156 |
|
|
|
157 |
|
|
C<$[> は C<use v5.16> の元では無効になるようになりました。 |
158 |
|
|
これはデフォルト機能集合の一部で、 C<use feature 'array_base'> によって |
159 |
|
|
明示的に有効無効を切り替えられます。 |
160 |
|
|
|
161 |
|
|
=head2 C<__SUB__> |
162 |
|
|
|
163 |
|
|
=begin original |
164 |
|
|
|
165 |
|
|
The new C<__SUB__> token, available under the C<current_sub> feature |
166 |
|
|
(see L<feature>) or C<use v5.16>, returns a reference to the current |
167 |
|
|
subroutine, making it easier to write recursive closures. |
168 |
|
|
|
169 |
|
|
=end original |
170 |
|
|
|
171 |
|
|
C<current_sub> 機能 (L<feature> 参照) または C<use v5.16> で利用可能な |
172 |
|
|
C<__SUB__> トークンは現在のサブルーチンへのリファレンスを返すことで、 |
173 |
|
|
再帰クロージャを書くのを容易にします。 |
174 |
|
|
|
175 |
|
|
=head2 New and Improved Built-ins |
176 |
|
|
|
177 |
|
|
(新規または改良された組み込み関数) |
178 |
|
|
|
179 |
|
|
=head3 More consistent C<eval> |
180 |
|
|
|
181 |
|
|
(より一貫性のある C<eval>) |
182 |
|
|
|
183 |
|
|
=begin original |
184 |
|
|
|
185 |
|
|
The C<eval> operator sometimes treats a string argument as a sequence of |
186 |
|
|
characters and sometimes as a sequence of bytes, depending on the |
187 |
|
|
internal encoding. The internal encoding is not supposed to make any |
188 |
|
|
difference, but there is code that relies on this inconsistency. |
189 |
|
|
|
190 |
|
|
=end original |
191 |
|
|
|
192 |
|
|
C<eval> 演算子は内部エンコーディングに依存して、時には文字列引数を |
193 |
|
|
文字の並びとして、時にはバイトの並びとして扱います。 |
194 |
|
|
内部エンコーディングは何の違いもないはずですが、この非一貫性に依存した |
195 |
|
|
コードがあります。 |
196 |
|
|
|
197 |
|
|
=begin original |
198 |
|
|
|
199 |
|
|
The new C<unicode_eval> and C<evalbytes> features (enabled under C<use |
200 |
argrath |
1.2 |
5.16.0>) resolve this. The C<unicode_eval> feature causes C<eval |
201 |
argrath |
1.1 |
$string> to treat the string always as Unicode. The C<evalbytes> |
202 |
|
|
features provides a function, itself called C<evalbytes>, which |
203 |
|
|
evaluates its argument always as a string of bytes. |
204 |
|
|
|
205 |
|
|
=end original |
206 |
|
|
|
207 |
|
|
(C<use 5.16.0> で有効になる)新しい C<unicode_eval> 機能と |
208 |
|
|
C<evalbytes> 機能はこれを解決します。 |
209 |
|
|
C<unicode_eval> 機能は、C<eval $string> での文字列を常に Unicode として |
210 |
|
|
扱います。 |
211 |
|
|
C<evalbytes> 機能は、引数を常にバイト列として扱う C<evalbytes> 関数を |
212 |
|
|
提供します。 |
213 |
|
|
|
214 |
|
|
=begin original |
215 |
|
|
|
216 |
|
|
These features also fix oddities with source filters leaking to outer |
217 |
|
|
dynamic scopes. |
218 |
|
|
|
219 |
|
|
=end original |
220 |
|
|
|
221 |
|
|
これらの機能は、ソースフィルタが外側の動的スコープにリークする問題も |
222 |
|
|
修正します。 |
223 |
|
|
|
224 |
|
|
=begin original |
225 |
|
|
|
226 |
|
|
See L<feature> for more detail. |
227 |
|
|
|
228 |
|
|
=end original |
229 |
|
|
|
230 |
|
|
さらなる詳細については L<feature> を参照してください。 |
231 |
|
|
|
232 |
|
|
=head3 C<substr> lvalue revamp |
233 |
|
|
|
234 |
|
|
(C<substr> 左辺値の刷新) |
235 |
|
|
|
236 |
argrath |
1.3 |
=for comment Does this belong here, or under Incomptable Changes? |
237 |
argrath |
1.1 |
|
238 |
|
|
=begin original |
239 |
|
|
|
240 |
|
|
When C<substr> is called in lvalue or potential lvalue context with two |
241 |
|
|
or three arguments, a special lvalue scalar is returned that modifies |
242 |
|
|
the original string (the first argument) when assigned to. |
243 |
|
|
|
244 |
|
|
=end original |
245 |
|
|
|
246 |
|
|
左辺値や潜在的な左辺値コンテキストで 2 引数または 3 引数の C<substr> が |
247 |
|
|
呼び出されると、代入するときに元の文字列(1 番目の引数)を修正する |
248 |
|
|
特殊な左辺値スカラを返します。 |
249 |
|
|
|
250 |
|
|
=begin original |
251 |
|
|
|
252 |
|
|
Previously, the offsets (the second and third arguments) passed to |
253 |
|
|
C<substr> would be converted immediately to match the string, negative |
254 |
|
|
offsets being translated to positive and offsets beyond the end of the |
255 |
|
|
string being truncated. |
256 |
|
|
|
257 |
|
|
=end original |
258 |
|
|
|
259 |
|
|
以前は、C<substr> に渡されたオフセット(2 番目と 3 番目の引数) は直ちに |
260 |
|
|
文字列にマッチするように変換され、負のオフセットは正に変換され、 |
261 |
|
|
文字列の末尾を越えるオフセットは切り詰められました。 |
262 |
|
|
|
263 |
|
|
=begin original |
264 |
|
|
|
265 |
|
|
Now, the offsets are recorded without modification in the special |
266 |
|
|
lvalue scalar that is returned, and the original string is not even |
267 |
|
|
looked at by C<substr> itself, but only when the returned lvalue is |
268 |
|
|
read or modified. |
269 |
|
|
|
270 |
|
|
=end original |
271 |
|
|
|
272 |
|
|
今では、オフセットは返される特殊左辺値スカラに修正なしに記録され、 |
273 |
|
|
元の文字列は C<substr> 自身によっても見ませんが、返された左辺値は |
274 |
|
|
読んだり修正したりしたときだけです。 |
275 |
|
|
|
276 |
|
|
=begin original |
277 |
|
|
|
278 |
argrath |
1.3 |
These changes result in an incompatible change: |
279 |
argrath |
1.1 |
|
280 |
|
|
=end original |
281 |
|
|
|
282 |
argrath |
1.3 |
これらの変更はいくつかの互換性のない変更を引き起こします: |
283 |
argrath |
1.1 |
|
284 |
|
|
=begin original |
285 |
|
|
|
286 |
|
|
If the original string changes length after the call to C<substr> but |
287 |
|
|
before assignment to its return value, negative offsets will remember |
288 |
|
|
their position from the end of the string, affecting code like this: |
289 |
|
|
|
290 |
|
|
=end original |
291 |
|
|
|
292 |
|
|
C<substr> を呼び出した後、返り値が代入される前に、元の文字列の長さが |
293 |
|
|
変更されると、負のオフセットは文字列の末尾からの位置を覚えているので、 |
294 |
|
|
以下のようなコードに影響を与えます: |
295 |
|
|
|
296 |
|
|
my $string = "string"; |
297 |
|
|
my $lvalue = \substr $string, -4, 2; |
298 |
|
|
print $lvalue, "\n"; # prints "ri" |
299 |
|
|
$string = "bailing twine"; |
300 |
|
|
print $lvalue, "\n"; # prints "wi"; used to print "il" |
301 |
|
|
|
302 |
|
|
=begin original |
303 |
|
|
|
304 |
|
|
The same thing happens with an omitted third argument. The returned |
305 |
|
|
lvalue will always extend to the end of the string, even if the string |
306 |
|
|
becomes longer. |
307 |
|
|
|
308 |
|
|
=end original |
309 |
|
|
|
310 |
|
|
同じことは省略された 3 番目の引数でも起こります。 |
311 |
|
|
返された左辺値は、たとえ文字列が長くなっても、常に文字列の末尾に |
312 |
|
|
拡張されます。 |
313 |
|
|
|
314 |
|
|
=begin original |
315 |
|
|
|
316 |
argrath |
1.3 |
Since this change also allowed many bugs to be fixed (see |
317 |
argrath |
1.5 |
L</The C<substr> operator>), and since the behaviour |
318 |
argrath |
1.16 |
of negative offsets has never been specified, the |
319 |
argrath |
1.1 |
change was deemed acceptable. |
320 |
|
|
|
321 |
|
|
=end original |
322 |
|
|
|
323 |
argrath |
1.5 |
この変更により多くのバグを修正できるようになり、 |
324 |
|
|
L</Fixes to the C<substr> operator> を参照してください)、 |
325 |
argrath |
1.3 |
負数のオフセットの振る舞いは仕様になったことはないので、この変更は |
326 |
|
|
受け入れられる取引でした。 |
327 |
argrath |
1.1 |
|
328 |
|
|
=head3 Return value of C<tied> |
329 |
|
|
|
330 |
|
|
(C<tied> の返り値) |
331 |
|
|
|
332 |
|
|
=begin original |
333 |
|
|
|
334 |
|
|
The value returned by C<tied> on a tied variable is now the actual |
335 |
|
|
scalar that holds the object to which the variable is tied. This |
336 |
|
|
allows ties to be weakened with C<Scalar::Util::weaken(tied |
337 |
|
|
$tied_variable)>. |
338 |
|
|
|
339 |
|
|
=end original |
340 |
|
|
|
341 |
|
|
tie された変数に対する C<tied> によって返される値は、変数が tie された |
342 |
|
|
オブジェクトを保持する実際のスカラになりました。 |
343 |
|
|
これにより C<Scalar::Util::weaken(tied $tied_variable)> で tie を |
344 |
|
|
弱めることが出来るようになります。 |
345 |
|
|
|
346 |
|
|
=head2 Unicode Support |
347 |
|
|
|
348 |
|
|
(Unicode 対応) |
349 |
|
|
|
350 |
|
|
=head3 Supports (I<almost>) Unicode 6.1 |
351 |
|
|
|
352 |
argrath |
1.2 |
((I<ほぼ>) Unicode 6.1 対応) |
353 |
|
|
|
354 |
argrath |
1.1 |
=begin original |
355 |
|
|
|
356 |
|
|
Besides the addition of whole new scripts, and new characters in |
357 |
|
|
existing scripts, this new version of Unicode, as always, makes some |
358 |
|
|
changes to existing characters. One change that may trip up some |
359 |
|
|
applications is that the General Category of two characters in the |
360 |
|
|
Latin-1 range, PILCROW SIGN and SECTION SIGN, has been changed from |
361 |
|
|
Other_Symbol to Other_Punctuation. The same change has been made for |
362 |
|
|
a character in each of Tibetan, Ethiopic, and Aegean. |
363 |
|
|
The code points U+3248..U+324F (CIRCLED NUMBER TEN ON BLACK SQUARE |
364 |
|
|
through CIRCLED NUMBER EIGHTY ON BLACK SQUARE) have had their General |
365 |
|
|
Category changed from Other_Symbol to Other_Numeric. The Line Break |
366 |
|
|
property has changes for Hebrew and Japanese; and as a consequence of |
367 |
|
|
other changes in 6.1, the Perl regular expression construct C<\X> now |
368 |
|
|
works differently for some characters in Thai and Lao. |
369 |
|
|
|
370 |
|
|
=end original |
371 |
|
|
|
372 |
|
|
完全に新しい用字や、既にある用字への新しい文字の他に、新しい |
373 |
|
|
Unicode はいつも通り、既にある文字もいくつか変更しています。 |
374 |
|
|
アプリケーションをつまずかせるかもしれない変更の一つは、 |
375 |
|
|
Latin-1 の範囲にある二つの文字 PILCROW SIGN および SECTION SIGN の |
376 |
|
|
一般カテゴリは Other_Symbol から Other_Punctuation に変更されました。 |
377 |
|
|
同じ変更は Tibetan, Ethiopic, Aegean の文字に対しても行われました。 |
378 |
|
|
符号位置 U+3248..U+324F (CIRCLED NUMBER TEN ON BLACK SQUARE から |
379 |
|
|
CIRCLED NUMBER EIGHTY ON BLACK SQUARE) の一般カテゴリは |
380 |
|
|
Other_Symbol から Other_Numeric に変更されました。 |
381 |
|
|
Line Break 特性は Hebrew と Japanese で変更されました; そして 6.1 での |
382 |
|
|
その他の変更の結果として、Perl の正規表現構造 C<\X> は Thai と Lao の |
383 |
|
|
いくつかの文字では異なった動作をします。 |
384 |
|
|
|
385 |
|
|
=begin original |
386 |
|
|
|
387 |
|
|
New aliases (synonyms) have been defined for many property values; |
388 |
|
|
these, along with the previously existing ones, are all cross-indexed in |
389 |
|
|
L<perluniprops>. |
390 |
|
|
|
391 |
|
|
=end original |
392 |
|
|
|
393 |
|
|
新しい別名が多くの特性値に定義されました; これらは、既に存在するものと |
394 |
|
|
あわせて、全て L<perluniprops> にクロスインデックスされています。 |
395 |
|
|
|
396 |
|
|
=begin original |
397 |
|
|
|
398 |
|
|
The return value of C<charnames::viacode()> is affected by other |
399 |
|
|
changes: |
400 |
|
|
|
401 |
|
|
=end original |
402 |
|
|
|
403 |
|
|
C<charnames::viacode()> の帰り値はその他の変更の影響を受けます: |
404 |
|
|
|
405 |
|
|
Code point Old Name New Name |
406 |
|
|
U+000A LINE FEED (LF) LINE FEED |
407 |
|
|
U+000C FORM FEED (FF) FORM FEED |
408 |
|
|
U+000D CARRIAGE RETURN (CR) CARRIAGE RETURN |
409 |
|
|
U+0085 NEXT LINE (NEL) NEXT LINE |
410 |
|
|
U+008E SINGLE-SHIFT 2 SINGLE-SHIFT-2 |
411 |
|
|
U+008F SINGLE-SHIFT 3 SINGLE-SHIFT-3 |
412 |
|
|
U+0091 PRIVATE USE 1 PRIVATE USE-1 |
413 |
|
|
U+0092 PRIVATE USE 2 PRIVATE USE-2 |
414 |
|
|
U+2118 SCRIPT CAPITAL P WEIERSTRASS ELLIPTIC FUNCTION |
415 |
|
|
|
416 |
|
|
=begin original |
417 |
|
|
|
418 |
|
|
Perl will accept any of these names as input, but |
419 |
|
|
C<charnames::viacode()> now returns the new name of each pair. The |
420 |
|
|
change for U+2118 is considered by Unicode to be a correction, that is |
421 |
|
|
the original name was a mistake (but again, it will remain forever valid |
422 |
|
|
to use it to refer to U+2118). But most of these changes are the |
423 |
|
|
fallout of the mistake Unicode 6.0 made in naming a character used in |
424 |
|
|
Japanese cell phones to be "BELL", which conflicts with the longstanding |
425 |
|
|
industry use of (and Unicode's recommendation to use) that name |
426 |
|
|
to mean the ASCII control character at U+0007. As a result, that name |
427 |
|
|
has been deprecated in Perl since v5.14; and any use of it will raise a |
428 |
|
|
warning message (unless turned off). The name "ALERT" is now the |
429 |
|
|
preferred name for this code point, with "BEL" being an acceptable short |
430 |
|
|
form. The name for the new cell phone character, at code point U+1F514, |
431 |
|
|
remains undefined in this version of Perl (hence we don't quite |
432 |
|
|
implement all of Unicode 6.1), but starting in v5.18, BELL will mean |
433 |
|
|
this character, and not U+0007. |
434 |
|
|
|
435 |
|
|
=end original |
436 |
|
|
|
437 |
|
|
Perl は任意の名前を入力として受け付けますが、C<charnames::viacode()> は |
438 |
|
|
それぞれのペアの新しい名前を返すようになりました。 |
439 |
|
|
U+2118 の変更は、元の名前が間違っていたための Unicode による訂正と |
440 |
|
|
考えられます(しかし再び、これは U+2118 を参照するために永遠に有効の |
441 |
|
|
ままです)。 |
442 |
|
|
しかしこれらの変更の中で最大のものは、日本の携帯電話で使われている |
443 |
|
|
文字の名前に、長い間実用されている (そして Unicode も使用を推奨している |
444 |
|
|
ASCII 制御文字 U+0007 と衝突している "BELL" という名前を付けたことによる |
445 |
|
|
副産物です。 |
446 |
|
|
結果として、この名前は v5.14 以降 Perl では非推奨となっています; |
447 |
|
|
そしてこれを使うと(オフにしていなければ)警告メッセージが発生します。 |
448 |
|
|
この符号位置に対する適切な名前は "ALERT" になり、短い形式として |
449 |
|
|
"BEL" が受け入れられるようになります。 |
450 |
|
|
このバージョンの Perl では、符号位置 U+1F514 の新しい携帯電話の文字の |
451 |
|
|
名前は未定義のままです(従って私たちは Unicode 6.1 の完全に全てを |
452 |
|
|
実装しているわけではありません)が、v5.18 から BELL は U+0007 ではなく |
453 |
|
|
この文字を意味するようになります。 |
454 |
|
|
|
455 |
|
|
=begin original |
456 |
|
|
|
457 |
|
|
Unicode has taken steps to make sure that this sort of mistake does not |
458 |
|
|
happen again. The Standard now includes all the generally accepted |
459 |
|
|
names and abbreviations for control characters, whereas previously it |
460 |
|
|
didn't (though there were recommended names for most of them, which Perl |
461 |
|
|
used). This means that most of those recommended names are now |
462 |
|
|
officially in the Standard. Unicode did not recommend names for the |
463 |
|
|
four code points listed above between U+008E and U+008F, and in |
464 |
|
|
standardizing them Unicode subtly changed the names that Perl had |
465 |
|
|
previously given them, by replacing the final blank in each name by a |
466 |
|
|
hyphen. Unicode also officially accepts names that Perl had deprecated, |
467 |
|
|
such as FILE SEPARATOR. Now the only deprecated name is BELL. |
468 |
|
|
Finally, Perl now uses the new official names instead of the old |
469 |
|
|
(now considered obsolete) names for the first four code points in the |
470 |
|
|
list above (the ones which have the parentheses in them). |
471 |
|
|
|
472 |
|
|
=end original |
473 |
|
|
|
474 |
|
|
Unicode はこのような過ちが再び起きないようにするための対策を取りました。 |
475 |
|
|
今では標準には制御文字に対して、全ての一般的に受け入れられている名前を |
476 |
|
|
含むようになりました(以前は含んでいませんでしたが、そのほとんどは |
477 |
|
|
Perl が使っていた推奨される名前でした)。 |
478 |
|
|
Unicode は U+008E から U+008F の間の上述の四つの符号位置に対する |
479 |
argrath |
1.14 |
名前を推奨しておらず、これらを標準化する際に Unicode は Perl が以前 |
480 |
|
|
与えていた名前を、それぞれの名前の最後の空白をハイフンにすることで |
481 |
|
|
微妙に変更しました。 |
482 |
argrath |
1.1 |
Unicode はまた、FILE SEPARATOR のように Perl では非推奨とした名前を |
483 |
|
|
公式に受け入れました。 |
484 |
|
|
今では唯一の非推奨の名前は BELL です。 |
485 |
|
|
最終的に、上述の四つの符号位置の名前として古い(今では古いものとなったと |
486 |
|
|
考えられる)名前ではなく、新しい公式の名前(かっこで囲まれたもの)を使います。 |
487 |
|
|
|
488 |
|
|
=begin original |
489 |
|
|
|
490 |
|
|
Now that the names have been placed in the Unicode standard, these kinds |
491 |
|
|
of changes should not happen again, though corrections, such as to |
492 |
|
|
U+2118, are still possible. |
493 |
|
|
|
494 |
|
|
=end original |
495 |
|
|
|
496 |
|
|
名前が Unicode 標準に入ったことにより、この種の変更は再び発生することは |
497 |
|
|
ありませんが、U+2118 に対するような修正は引き続き起こりえます。 |
498 |
|
|
|
499 |
|
|
=begin original |
500 |
|
|
|
501 |
|
|
Unicode also added some name abbreviations, which Perl now accepts: |
502 |
|
|
SP for SPACE; |
503 |
|
|
TAB for CHARACTER TABULATION; |
504 |
|
|
NEW LINE, END OF LINE, NL, and EOL for LINE FEED; |
505 |
|
|
LOCKING-SHIFT ONE for SHIFT OUT; |
506 |
|
|
LOCKING-SHIFT ZERO for SHIFT IN; |
507 |
|
|
and ZWNBSP for ZERO WIDTH NO-BREAK SPACE. |
508 |
|
|
|
509 |
|
|
=end original |
510 |
|
|
|
511 |
|
|
Unicode はまたいくつかの名前の略称を追加し、Perl でも使えるようになりました: |
512 |
|
|
SPACE 用に SP; |
513 |
|
|
CHARACTER TABULATION 用に TAB; |
514 |
|
|
LINE FEED 用に NEW LINE, END OF LINE, NL, EOL; |
515 |
|
|
SHIFT OUT 用に LOCKING-SHIFT ONE; |
516 |
|
|
SHIFT IN 用に LOCKING-SHIFT ZERO; |
517 |
|
|
ZERO WIDTH NO-BREAK SPACE 用に ZWNBSP。 |
518 |
|
|
|
519 |
|
|
=begin original |
520 |
|
|
|
521 |
|
|
More details on this version of Unicode are provided in |
522 |
|
|
L<http://www.unicode.org/versions/Unicode6.1.0/>. |
523 |
|
|
|
524 |
|
|
=end original |
525 |
|
|
|
526 |
|
|
このバージョンの Unicode に関するさらなる詳細は |
527 |
|
|
L<http://www.unicode.org/versions/Unicode6.1.0/> で提供されています。 |
528 |
|
|
|
529 |
|
|
=head3 C<use charnames> is no longer needed for C<\N{I<name>}> |
530 |
|
|
|
531 |
argrath |
1.2 |
(C<\N{I<name>}> には C<use charnames> は不要に) |
532 |
|
|
|
533 |
argrath |
1.1 |
=begin original |
534 |
|
|
|
535 |
|
|
When C<\N{I<name>}> is encountered, the C<charnames> module is now |
536 |
|
|
automatically loaded when needed as if the C<:full> and C<:short> |
537 |
|
|
options had been specified. See L<charnames> for more information. |
538 |
|
|
|
539 |
|
|
=end original |
540 |
|
|
|
541 |
|
|
C<\N{I<name>}> に遭遇すると、必要なら C<:full> と C<:short> のオプションが |
542 |
|
|
指定されたかのように C<charnames> モジュールが自動的に読み込まれるように |
543 |
|
|
なりました。 |
544 |
|
|
さらなる情報については L<charnames> を参照してください。 |
545 |
|
|
|
546 |
|
|
=head3 C<\N{...}> can now have Unicode loose name matching |
547 |
|
|
|
548 |
argrath |
1.2 |
(C<\N{...}> は Unicode の緩い名前のマッチングに) |
549 |
|
|
|
550 |
argrath |
1.1 |
=begin original |
551 |
|
|
|
552 |
|
|
This is described in the C<charnames> item in |
553 |
|
|
L</Updated Modules and Pragmata> below. |
554 |
|
|
|
555 |
|
|
=end original |
556 |
|
|
|
557 |
|
|
これは後述する L</Updated Modules and Pragmata> の |
558 |
|
|
C<charnames> に記述されています。 |
559 |
|
|
|
560 |
|
|
=head3 Unicode Symbol Names |
561 |
|
|
|
562 |
argrath |
1.2 |
(Unicode シンボル名) |
563 |
|
|
|
564 |
argrath |
1.1 |
=begin original |
565 |
|
|
|
566 |
|
|
Perl now has proper support for Unicode in symbol names. It used to be |
567 |
|
|
that C<*{$foo}> would ignore the internal UTF8 flag and use the bytes of |
568 |
|
|
the underlying representation to look up the symbol. That meant that |
569 |
|
|
C<*{"\x{100}"}> and C<*{"\xc4\x80"}> would return the same thing. All |
570 |
|
|
these parts of Perl have been fixed to account for Unicode: |
571 |
|
|
|
572 |
|
|
=end original |
573 |
|
|
|
574 |
|
|
Perl はシンボル名に対する Unicode 対応を適切に行うようになりました。 |
575 |
|
|
今までは C<*{$foo}> は内部 UTF8フラグを無視して、基となっているバイト列を |
576 |
|
|
使います。 |
577 |
|
|
|
578 |
|
|
=over |
579 |
|
|
|
580 |
|
|
=item * |
581 |
|
|
|
582 |
|
|
=begin original |
583 |
|
|
|
584 |
|
|
Method names (including those passed to C<use overload>) |
585 |
|
|
|
586 |
|
|
=end original |
587 |
|
|
|
588 |
|
|
メソッド名 (C<use overload> に渡されるものも含みます) |
589 |
|
|
|
590 |
|
|
=item * |
591 |
|
|
|
592 |
|
|
=begin original |
593 |
|
|
|
594 |
|
|
Typeglob names (including names of variables, subroutines and filehandles) |
595 |
|
|
|
596 |
|
|
=end original |
597 |
|
|
|
598 |
|
|
型グロブ名 (変数、サブルーチン、ファイルハンドルの名前を含みます) |
599 |
|
|
|
600 |
|
|
=item * |
601 |
|
|
|
602 |
|
|
=begin original |
603 |
|
|
|
604 |
|
|
Package names |
605 |
|
|
|
606 |
|
|
=end original |
607 |
|
|
|
608 |
|
|
パッケージ名 |
609 |
|
|
|
610 |
|
|
=item * |
611 |
|
|
|
612 |
|
|
C<goto> |
613 |
|
|
|
614 |
|
|
=item * |
615 |
|
|
|
616 |
|
|
=begin original |
617 |
|
|
|
618 |
|
|
Symbolic dereferencing |
619 |
|
|
|
620 |
|
|
=end original |
621 |
|
|
|
622 |
|
|
シンボリックなデリファレンス |
623 |
|
|
|
624 |
|
|
=item * |
625 |
|
|
|
626 |
|
|
=begin original |
627 |
|
|
|
628 |
|
|
Second argument to C<bless()> and C<tie()> |
629 |
|
|
|
630 |
|
|
=end original |
631 |
|
|
|
632 |
|
|
C<bless()> と C<tie()> への第 2 引数 |
633 |
|
|
|
634 |
|
|
=item * |
635 |
|
|
|
636 |
|
|
=begin original |
637 |
|
|
|
638 |
|
|
Return value of C<ref()> |
639 |
|
|
|
640 |
|
|
=end original |
641 |
|
|
|
642 |
|
|
C<ref()> の返り値 |
643 |
|
|
|
644 |
|
|
=item * |
645 |
|
|
|
646 |
|
|
=begin original |
647 |
|
|
|
648 |
|
|
Subroutine prototypes |
649 |
|
|
|
650 |
|
|
=end original |
651 |
|
|
|
652 |
|
|
サブルーチンプロトタイプ |
653 |
|
|
|
654 |
|
|
=item * |
655 |
|
|
|
656 |
|
|
=begin original |
657 |
|
|
|
658 |
|
|
Attributes |
659 |
|
|
|
660 |
|
|
=end original |
661 |
|
|
|
662 |
|
|
属性 |
663 |
|
|
|
664 |
|
|
=item * |
665 |
|
|
|
666 |
|
|
=begin original |
667 |
|
|
|
668 |
|
|
Various warnings and error messages that mention variable names or values, |
669 |
|
|
methods, etc. |
670 |
|
|
|
671 |
|
|
=end original |
672 |
|
|
|
673 |
|
|
変数名や値、メソッドなどに言及する様々な警告やエラーメッセージ |
674 |
|
|
|
675 |
|
|
=back |
676 |
|
|
|
677 |
|
|
=begin original |
678 |
|
|
|
679 |
|
|
In addition, a parsing bug has been fixed that prevented C<*{é}> from |
680 |
|
|
implicitly quoting the name, but instead interpreted it as C<*{+é}>, which |
681 |
|
|
would cause a strict violation. |
682 |
|
|
|
683 |
|
|
=end original |
684 |
|
|
|
685 |
argrath |
1.5 |
さらに、C<*{é}> を暗黙にクォートする名前から除外するバグが修正され、 |
686 |
|
|
strict 違反となる C<*{+é}> として解釈されるようになりました。 |
687 |
argrath |
1.1 |
|
688 |
|
|
=begin original |
689 |
|
|
|
690 |
|
|
C<*{"*a::b"}> automatically strips off the * if it is followed by an ASCII |
691 |
|
|
letter. That has been extended to all Unicode identifier characters. |
692 |
|
|
|
693 |
|
|
=end original |
694 |
|
|
|
695 |
|
|
C<*{"*a::b"}> は、* の後に ASCII 文字が引き続いている場合は * が自動的に |
696 |
|
|
削除されます。 |
697 |
|
|
これは全ての Unicode 識別子文字に拡張されました。 |
698 |
|
|
|
699 |
|
|
=begin original |
700 |
|
|
|
701 |
argrath |
1.2 |
One-character non-ASCII non-punctuation variables (like C<$é>) are now |
702 |
|
|
subject to "Used only once" warnings. They used to be exempt, as they |
703 |
argrath |
1.16 |
were treated as punctuation variables. |
704 |
argrath |
1.1 |
|
705 |
|
|
=end original |
706 |
|
|
|
707 |
argrath |
1.2 |
(C<$é> のような) 単一文字非 ASCII 非句読点変数はは |
708 |
|
|
"Used only once" 警告を出すようになりました。 |
709 |
argrath |
1.1 |
今までは、これは句読点変数として扱われていたので警告から免れていました。 |
710 |
|
|
|
711 |
|
|
=begin original |
712 |
|
|
|
713 |
argrath |
1.7 |
Also, single-character Unicode punctuation variables (like C<$‰>) are now |
714 |
argrath |
1.2 |
supported [perl #69032]. |
715 |
argrath |
1.1 |
|
716 |
|
|
=end original |
717 |
|
|
|
718 |
argrath |
1.7 |
また、(C<$‰> のような)単一文字の Unicode 句読点変数に対応しました |
719 |
argrath |
1.1 |
[perl #69032]。 |
720 |
|
|
|
721 |
|
|
=head3 Improved ability to mix locales and Unicode, including UTF-8 locales |
722 |
|
|
|
723 |
argrath |
1.2 |
((UTF-8 ロケールを含む)ロケールと Unicode を混ぜる能力の改善) |
724 |
|
|
|
725 |
argrath |
1.1 |
=begin original |
726 |
|
|
|
727 |
|
|
An optional parameter has been added to C<use locale> |
728 |
|
|
|
729 |
|
|
=end original |
730 |
|
|
|
731 |
|
|
C<use locale> にオプションの引数が追加されました: |
732 |
|
|
|
733 |
|
|
use locale ':not_characters'; |
734 |
|
|
|
735 |
|
|
=begin original |
736 |
|
|
|
737 |
|
|
which tells Perl to use all but the C<LC_CTYPE> and C<LC_COLLATE> |
738 |
|
|
portions of the current locale. Instead, the character set is assumed |
739 |
|
|
to be Unicode. This allows locales and Unicode to be seamlessly mixed, |
740 |
|
|
including the increasingly frequent UTF-8 locales. When using this |
741 |
|
|
hybrid form of locales, the C<:locale> layer to the L<open> pragma can |
742 |
|
|
be used to interface with the file system, and there are CPAN modules |
743 |
|
|
available for ARGV and environment variable conversions. |
744 |
|
|
|
745 |
|
|
=end original |
746 |
|
|
|
747 |
|
|
は、現在のロケールのうち、C<LC_CTYPE> と C<LC_COLLATE> 以外の全てを |
748 |
|
|
使うことを Perl に知らせます。 |
749 |
|
|
それ以外では、文字集合は Unicode であると仮定します。 |
750 |
|
|
これにより、徐々に頻繁に出てくる UTF-8 ロケールを含む、ロケールと |
751 |
|
|
Unicode をシームレスに混ぜることが出来るようになります。 |
752 |
|
|
このハイブリッド形式のロケールを使うとき、 |
753 |
|
|
L<open> への C<:locale> 層をファイルシステムへのインターフェースとして |
754 |
|
|
使うことができ、ARGV と環境変数の変換のための CPAN モジュールを |
755 |
|
|
利用可能です。 |
756 |
|
|
|
757 |
|
|
=begin original |
758 |
|
|
|
759 |
|
|
Full details are in L<perllocale>. |
760 |
|
|
|
761 |
|
|
=end original |
762 |
|
|
|
763 |
|
|
完全な詳細は L<perllocale> にあります。 |
764 |
|
|
|
765 |
|
|
=head3 New function C<fc> and corresponding escape sequence C<\F> for Unicode foldcase |
766 |
|
|
|
767 |
argrath |
1.2 |
(Unicode 畳み込み文字のための新しい関数 C<fc> と対応するエスケープシーケンス C<\F>) |
768 |
|
|
|
769 |
argrath |
1.1 |
=begin original |
770 |
|
|
|
771 |
|
|
Unicode foldcase is an extension to lowercase that gives better results |
772 |
|
|
when comparing two strings case-insensitively. It has long been used |
773 |
|
|
internally in regular expression C</i> matching. Now it is available |
774 |
|
|
explicitly through the new C<fc> function call (enabled by |
775 |
|
|
S<C<"use feature 'fc'">>, or C<use v5.16>, or explicitly callable via |
776 |
|
|
C<CORE::fc>) or through the new C<\F> sequence in double-quotish |
777 |
|
|
strings. |
778 |
|
|
|
779 |
|
|
=end original |
780 |
|
|
|
781 |
|
|
Unicode の畳み込み文字は、二つの文字列を大文字小文字を無視して比較するときに |
782 |
|
|
よりよい結果を与えるための小文字の拡張です。 |
783 |
|
|
これは長い間正規表現の C</i> マッチングで内部で使われていました。 |
784 |
|
|
これは (S<C<"use feature 'fc'">>、C<use v5.16> で有効にするか、 |
785 |
|
|
明示的な C<CORE::fc> で明示的に呼び出し可能な)新しい C<fc> 関数呼び出しか、 |
786 |
|
|
ダブルクォート風の文字列の中の新しい C<\F> シーケンスを通して |
787 |
|
|
利用可能になりました。 |
788 |
|
|
|
789 |
|
|
=begin original |
790 |
|
|
|
791 |
|
|
Full details are in L<perlfunc/fc>. |
792 |
|
|
|
793 |
|
|
=end original |
794 |
|
|
|
795 |
|
|
完全な詳細は L<perlfunc/fc> にあります。 |
796 |
|
|
|
797 |
|
|
=head3 The Unicode C<Script_Extensions> property is now supported. |
798 |
|
|
|
799 |
argrath |
1.2 |
(Unicode の C<Script_Extensions> 特性に対応) |
800 |
|
|
|
801 |
argrath |
1.1 |
=begin original |
802 |
|
|
|
803 |
|
|
New in Unicode 6.0, this is an improved C<Script> property. Details |
804 |
|
|
are in L<perlunicode/Scripts>. |
805 |
|
|
|
806 |
|
|
=end original |
807 |
|
|
|
808 |
|
|
Unicode 6.0 からの新機能で、これは改良された C<Script> 特性です。 |
809 |
|
|
詳細は L<perlunicode/Scripts> にあります。 |
810 |
|
|
|
811 |
|
|
=head2 XS Changes |
812 |
|
|
|
813 |
|
|
=head3 Improved typemaps for Some Builtin Types |
814 |
|
|
|
815 |
argrath |
1.2 |
(いくつかの組み込み型の typemap の改善) |
816 |
|
|
|
817 |
argrath |
1.1 |
=begin original |
818 |
|
|
|
819 |
|
|
Most XS authors will be aware that there is a longstanding bug in the |
820 |
|
|
OUTPUT typemap for T_AVREF (C<AV*>), T_HVREF (C<HV*>), T_CVREF (C<CV*>), |
821 |
|
|
and T_SVREF (C<SVREF> or C<\$foo>) that requires manually decrementing |
822 |
|
|
the reference count of the return value instead of the typemap taking |
823 |
|
|
care of this. For backwards-compatibility, this cannot be changed in the |
824 |
|
|
default typemaps. But we now provide additional typemaps |
825 |
|
|
C<T_AVREF_REFCOUNT_FIXED>, etc. that do not exhibit this bug. Using |
826 |
|
|
them in your extension is as simple as having one line in your |
827 |
|
|
C<TYPEMAP> section: |
828 |
|
|
|
829 |
|
|
=end original |
830 |
|
|
|
831 |
argrath |
1.6 |
ほとんどの XS 作者は、T_AVREF (C<AV*>), T_HVREF (C<HV*>), T_CVREF (C<CV*>), |
832 |
|
|
T_SVREF (C<SVREF> または C<\$foo>) の OUTPUT typemap は参照カウントを |
833 |
|
|
typemap が面倒を見てくれず、手動で減らす必要があるという長い間ある |
834 |
|
|
バグに気付いていました。 |
835 |
argrath |
1.1 |
後方互換性のために、これはデフォルトの typemap では変更できません。 |
836 |
|
|
しかし、この問題が含まれない |
837 |
|
|
C<T_AVREF_REFCOUNT_FIXED> などの追加の typemap を提供することになりました。 |
838 |
|
|
エクステンションでこれらを使うことで、 |
839 |
|
|
C<TYPEMAP> セクションを 1 行にまで単純化できます: |
840 |
|
|
|
841 |
|
|
HV* T_HVREF_REFCOUNT_FIXED |
842 |
|
|
|
843 |
|
|
=head3 C<is_utf8_char()> |
844 |
|
|
|
845 |
|
|
=begin original |
846 |
|
|
|
847 |
|
|
The XS-callable function C<is_utf8_char()>, when presented with |
848 |
|
|
malformed UTF-8 input, can read up to 12 bytes beyond the end of the |
849 |
argrath |
1.16 |
string. This cannot be fixed without changing its API, and so its |
850 |
|
|
use is now deprecated. Use C<is_utf8_char_buf()> (described just below) |
851 |
|
|
instead. |
852 |
argrath |
1.1 |
|
853 |
|
|
=end original |
854 |
|
|
|
855 |
|
|
XS 呼び出し可能な関数 C<is_utf8_char()> は、不正な UTF-8 入力があると、 |
856 |
|
|
文字列の終わりを越えて最大 12 バイト読む可能性があります。 |
857 |
argrath |
1.16 |
これは API を変更せずに修正することはできないので、この使用は |
858 |
|
|
非推奨になりました。 |
859 |
|
|
代わりに (この後に記述している) C<is_utf8_char_buf()> を使ってください。 |
860 |
argrath |
1.1 |
|
861 |
|
|
=head3 Added C<is_utf8_char_buf()> |
862 |
|
|
|
863 |
argrath |
1.2 |
(C<is_utf8_char_buf()> の追加) |
864 |
|
|
|
865 |
argrath |
1.1 |
=begin original |
866 |
|
|
|
867 |
|
|
This function is designed to replace the deprecated L</is_utf8_char()> |
868 |
|
|
function. It includes an extra parameter to make sure it doesn't read |
869 |
|
|
past the end of the input buffer. |
870 |
|
|
|
871 |
|
|
=end original |
872 |
|
|
|
873 |
|
|
この関数は非推奨の L</is_utf8_char()> 関数を置き換えるために |
874 |
|
|
設計されています。 |
875 |
|
|
これには入力バッファの末尾を越えて読み込まないようにするための追加の引数が |
876 |
|
|
あります。 |
877 |
|
|
|
878 |
|
|
=head3 Other C<is_utf8_foo()> functions, as well as C<utf8_to_foo()>, etc. |
879 |
|
|
|
880 |
argrath |
1.2 |
(C<utf8_to_foo()> のような、その他の C<is_utf8_foo()> 関数) |
881 |
|
|
|
882 |
argrath |
1.1 |
=begin original |
883 |
|
|
|
884 |
|
|
Most of the other XS-callable functions that take UTF-8 encoded input |
885 |
|
|
implicitly assume that the UTF-8 is valid (not malformed) in regards to |
886 |
|
|
buffer length. Do not do things such as change a character's case or |
887 |
|
|
see if it is alphanumeric without first being sure that it is valid |
888 |
|
|
UTF-8. This can be safely done for a whole string by using one of the |
889 |
|
|
functions C<is_utf8_string()>, C<is_utf8_string_loc()>, and |
890 |
|
|
C<is_utf8_string_loclen()>. |
891 |
|
|
|
892 |
|
|
=end original |
893 |
|
|
|
894 |
|
|
UTF-8 エンコードされた入力を取るその他の XS 呼び出し可能な関数のほとんどは |
895 |
|
|
バッファ長に関して UTF-8 が有効である(不正でない)ことを暗黙に |
896 |
|
|
仮定しています。 |
897 |
|
|
まず文字列が有効な UTF-8 であることを確認せずに、文字の大文字小文字を |
898 |
|
|
変更したり、英数字かどうかを確認したりしてはいけません。 |
899 |
|
|
このようなことは、文字列全体に対して C<is_utf8_string()>, |
900 |
|
|
C<is_utf8_string_loc()>, C<is_utf8_string_loclen()> のいずれかを使うことで |
901 |
|
|
安全に行えます。 |
902 |
|
|
|
903 |
|
|
=head3 New Pad API |
904 |
|
|
|
905 |
argrath |
1.2 |
(新しいパッド API) |
906 |
|
|
|
907 |
argrath |
1.1 |
=begin original |
908 |
|
|
|
909 |
|
|
Many new functions have been added to the API for manipulating lexical |
910 |
|
|
pads. See L<perlapi/Pad Data Structures> for more information. |
911 |
|
|
|
912 |
|
|
=end original |
913 |
|
|
|
914 |
|
|
レキシカルパッドを操作するための多くの新しい関数が API に追加されました。 |
915 |
|
|
さらなる情報については L<perlapi/Pad Data Structures> を参照してください。 |
916 |
|
|
|
917 |
|
|
=head2 Changes to Special Variables |
918 |
|
|
|
919 |
argrath |
1.2 |
(特殊変数に関する変更) |
920 |
|
|
|
921 |
argrath |
1.1 |
=head3 C<$$> can be assigned to |
922 |
|
|
|
923 |
argrath |
1.2 |
(C<$$> は代入可能に) |
924 |
|
|
|
925 |
argrath |
1.1 |
=begin original |
926 |
|
|
|
927 |
|
|
C<$$> was made read-only in Perl 5.8.0. But only sometimes: C<local $$> |
928 |
|
|
would make it writable again. Some CPAN modules were using C<local $$> or |
929 |
|
|
XS code to bypass the read-only check, so there is no reason to keep C<$$> |
930 |
|
|
read-only. (This change also allowed a bug to be fixed while maintaining |
931 |
|
|
backward compatibility.) |
932 |
|
|
|
933 |
|
|
=end original |
934 |
|
|
|
935 |
argrath |
1.14 |
C<$$> は Perl 5.8.0 で読み込み専用になりました。 |
936 |
argrath |
1.1 |
しかしときどき: C<local $$> で再び書き込み可能になることがあります。 |
937 |
|
|
CPAN モジュールによっては読み込み専用のチェックを回避するために |
938 |
argrath |
1.14 |
C<local $$> や XS コードを使っているものもあるので、C<$$> を読み込み専用に |
939 |
argrath |
1.1 |
保っておく理由がありません。 |
940 |
|
|
(この変更はまた、過去互換性を維持する間に修正するべきバグを許します。) |
941 |
|
|
|
942 |
|
|
=head3 C<$^X> converted to an absolute path on FreeBSD, OS X and Solaris |
943 |
|
|
|
944 |
argrath |
1.2 |
(FreeBSD, OS X, Solaris でも C<$^X> が絶対パスに変換されるように) |
945 |
|
|
|
946 |
argrath |
1.1 |
=begin original |
947 |
|
|
|
948 |
|
|
C<$^X> is now converted to an absolute path on OS X, FreeBSD (without |
949 |
|
|
needing F</proc> mounted) and Solaris 10 and 11. This augments the |
950 |
|
|
previous approach of using F</proc> on Linux, FreeBSD and NetBSD |
951 |
|
|
(in all cases, where mounted). |
952 |
|
|
|
953 |
|
|
=end original |
954 |
|
|
|
955 |
|
|
C<$^X> は、OS X、(F</proc> をマウントする必要のない) FreeBSD、 |
956 |
|
|
Solaris 10 と 11 では絶対パスに変換されるようになりました。 |
957 |
|
|
これは Linux, FreeBSD, NetBSD で(マウントされているときに) |
958 |
|
|
F</proc> を使うという以前の手法を拡大します。 |
959 |
|
|
|
960 |
|
|
=begin original |
961 |
|
|
|
962 |
|
|
This makes relocatable perl installations more useful on these platforms. |
963 |
|
|
(See "Relocatable @INC" in F<INSTALL>) |
964 |
|
|
|
965 |
|
|
=end original |
966 |
|
|
|
967 |
|
|
これにより、これらのプラットフォームでの再配置可能な perl インストールが |
968 |
|
|
より便利になります。 |
969 |
|
|
(F<INSTALL> の "Relocatable @INC" を参照してください。) |
970 |
|
|
|
971 |
|
|
=head2 Debugger Changes |
972 |
|
|
|
973 |
|
|
(デバッガの変更) |
974 |
|
|
|
975 |
|
|
=head3 Features inside the debugger |
976 |
|
|
|
977 |
|
|
(デバッガ内部の機能) |
978 |
|
|
|
979 |
|
|
=begin original |
980 |
|
|
|
981 |
|
|
The current Perl's L<feature> bundle is now enabled for commands entered |
982 |
|
|
in the interactive debugger. |
983 |
|
|
|
984 |
|
|
=end original |
985 |
|
|
|
986 |
|
|
現在の Perl の L<feature> バンドルは、対話的デバッガで入力されたコマンドで |
987 |
|
|
有効になるようになりました。 |
988 |
|
|
|
989 |
|
|
=head3 New option for the debugger's B<t> command |
990 |
|
|
|
991 |
|
|
(デバッガの B<t> コマンドの新しいオプション) |
992 |
|
|
|
993 |
|
|
=begin original |
994 |
|
|
|
995 |
|
|
The B<t> command in the debugger, which toggles tracing mode, now |
996 |
|
|
accepts a numeric argument that determines how many levels of subroutine |
997 |
|
|
calls to trace. |
998 |
|
|
|
999 |
|
|
=end original |
1000 |
|
|
|
1001 |
|
|
トレースモードをトグルするデバッガの B<t> コマンドは、サブルーチン |
1002 |
|
|
呼び出しを何レベルまでトレースするかを決定する数値引数を |
1003 |
|
|
受け付けるようになりました。 |
1004 |
|
|
|
1005 |
|
|
=head3 C<enable> and C<disable> |
1006 |
|
|
|
1007 |
|
|
(C<enable> と C<disable>) |
1008 |
|
|
|
1009 |
|
|
=begin original |
1010 |
|
|
|
1011 |
|
|
The debugger now has C<disable> and C<enable> commands for disabling |
1012 |
argrath |
1.2 |
existing breakpoints and re-enabling them. See L<perldebug>. |
1013 |
argrath |
1.1 |
|
1014 |
|
|
=end original |
1015 |
|
|
|
1016 |
|
|
デバッガに、すでに有るブレークポイントを無効にしたり、再び有効に |
1017 |
|
|
したりするためのC<disable> コマンドと C<enable> コマンドが追加されました。 |
1018 |
|
|
L<perldebug> を参照してください。 |
1019 |
|
|
|
1020 |
|
|
=head3 Breakpoints with file names |
1021 |
|
|
|
1022 |
|
|
(ファイル名付きのブレークポイント) |
1023 |
|
|
|
1024 |
|
|
=begin original |
1025 |
|
|
|
1026 |
|
|
The debugger's "b" command for setting breakpoints now allows a line |
1027 |
|
|
number to be prefixed with a file name. See |
1028 |
|
|
L<perldebug/"b [file]:[line] [condition]">. |
1029 |
|
|
|
1030 |
|
|
=end original |
1031 |
|
|
|
1032 |
|
|
ブレークポイントを設定するためのデバッガの "b" コマンドは、ファイル名の |
1033 |
|
|
後ろに付ける行番号を受け付けるようになりました。 |
1034 |
|
|
L<perldebug/"b [file]:[line] [condition]"> を参照してください。 |
1035 |
|
|
|
1036 |
|
|
=head2 The C<CORE> Namespace |
1037 |
|
|
|
1038 |
argrath |
1.2 |
(C<CORE> 名前空間) |
1039 |
|
|
|
1040 |
argrath |
1.1 |
=head3 The C<CORE::> prefix |
1041 |
|
|
|
1042 |
argrath |
1.14 |
(C<CORE::> 接頭辞) |
1043 |
argrath |
1.1 |
|
1044 |
|
|
=begin original |
1045 |
|
|
|
1046 |
|
|
The C<CORE::> prefix can now be used on keywords enabled by |
1047 |
|
|
L<feature.pm|feature>, even outside the scope of C<use feature>. |
1048 |
|
|
|
1049 |
|
|
=end original |
1050 |
|
|
|
1051 |
argrath |
1.14 |
C<CORE::> 接頭辞は、たとえ C<use feature> スコープの外側でも、 |
1052 |
argrath |
1.1 |
L<feature.pm|feature> で有効になるキーワードで使われるようになりました。 |
1053 |
|
|
|
1054 |
|
|
=head3 Subroutines in the C<CORE> namespace |
1055 |
|
|
|
1056 |
|
|
(C<CORE> 名前空間のサブルーチン) |
1057 |
|
|
|
1058 |
|
|
=begin original |
1059 |
|
|
|
1060 |
|
|
Many Perl keywords are now available as subroutines in the CORE namespace. |
1061 |
|
|
This allows them to be aliased: |
1062 |
|
|
|
1063 |
|
|
=end original |
1064 |
|
|
|
1065 |
|
|
多くの Perl キーワードが CORE 名前空間で利用可能になりました。 |
1066 |
|
|
これにより以下のように別名にできるようになります: |
1067 |
|
|
|
1068 |
|
|
BEGIN { *entangle = \&CORE::tie } |
1069 |
|
|
entangle $variable, $package, @args; |
1070 |
|
|
|
1071 |
|
|
=begin original |
1072 |
|
|
|
1073 |
|
|
And for prototypes to be bypassed: |
1074 |
|
|
|
1075 |
|
|
=end original |
1076 |
|
|
|
1077 |
|
|
そしてプロトタイプを回避するには: |
1078 |
|
|
|
1079 |
|
|
sub mytie(\[%$*@]$@) { |
1080 |
|
|
my ($ref, $pack, @args) = @_; |
1081 |
|
|
... do something ... |
1082 |
|
|
goto &CORE::tie; |
1083 |
|
|
} |
1084 |
|
|
|
1085 |
|
|
=begin original |
1086 |
|
|
|
1087 |
|
|
Some of these cannot be called through references or via C<&foo> syntax, |
1088 |
|
|
but must be called as barewords. |
1089 |
|
|
|
1090 |
|
|
=end original |
1091 |
|
|
|
1092 |
|
|
これらの一部はリファレンスや C<&foo> 文法では呼び出すことができず、 |
1093 |
|
|
裸の単語で呼び出さなければなりません。 |
1094 |
|
|
|
1095 |
|
|
=begin original |
1096 |
|
|
|
1097 |
|
|
See L<CORE> for details. |
1098 |
|
|
|
1099 |
|
|
=end original |
1100 |
|
|
|
1101 |
|
|
詳しくは L<CORE> を参照してください。 |
1102 |
|
|
|
1103 |
|
|
=head2 Other Changes |
1104 |
|
|
|
1105 |
argrath |
1.2 |
(その他の変更) |
1106 |
|
|
|
1107 |
argrath |
1.1 |
=head3 Anonymous handles |
1108 |
|
|
|
1109 |
argrath |
1.2 |
(無名ハンドル) |
1110 |
|
|
|
1111 |
argrath |
1.1 |
=begin original |
1112 |
|
|
|
1113 |
|
|
Automatically generated file handles are now named __ANONIO__ when the |
1114 |
|
|
variable name cannot be determined, rather than $__ANONIO__. |
1115 |
|
|
|
1116 |
|
|
=end original |
1117 |
|
|
|
1118 |
|
|
変数名が決定できないときに自動的に生成されるファイルハンドルの名前は |
1119 |
|
|
$__ANONIO__ ではなく __ANONIO__ になりました。 |
1120 |
|
|
|
1121 |
|
|
=head3 Autoloaded sort Subroutines |
1122 |
|
|
|
1123 |
argrath |
1.2 |
(ソートサブルーチンがオートロードされるように) |
1124 |
|
|
|
1125 |
argrath |
1.1 |
=begin original |
1126 |
|
|
|
1127 |
|
|
Custom sort subroutines can now be autoloaded [perl #30661]: |
1128 |
|
|
|
1129 |
|
|
=end original |
1130 |
|
|
|
1131 |
|
|
カスタムソートサブルーチンはオートロードされるようになりました |
1132 |
|
|
[perl #30661]: |
1133 |
|
|
|
1134 |
|
|
sub AUTOLOAD { ... } |
1135 |
|
|
@sorted = sort foo @list; # uses AUTOLOAD |
1136 |
|
|
|
1137 |
|
|
=head3 C<continue> no longer requires the "switch" feature |
1138 |
|
|
|
1139 |
argrath |
1.2 |
(C<continue> には "switch" は不要に) |
1140 |
|
|
|
1141 |
argrath |
1.1 |
=begin original |
1142 |
|
|
|
1143 |
|
|
The C<continue> keyword has two meanings. It can introduce a C<continue> |
1144 |
|
|
block after a loop, or it can exit the current C<when> block. Up till now, |
1145 |
|
|
the latter meaning was only valid with the "switch" feature enabled, and |
1146 |
|
|
was a syntax error otherwise. Since the main purpose of feature.pm is to |
1147 |
|
|
avoid conflicts with user-defined subroutines, there is no reason for |
1148 |
|
|
C<continue> to depend on it. |
1149 |
|
|
|
1150 |
|
|
=end original |
1151 |
|
|
|
1152 |
|
|
C<continue> キーワードには二つの意味があります。 |
1153 |
|
|
ループの後に C<continue> ブロックを導入する意味と、現在の C<when> ブロックを |
1154 |
|
|
出る意味です。 |
1155 |
|
|
今まで、後者の意味は "switch" 機能が有効の場合にのみ正当で、さもなければ |
1156 |
|
|
文法エラーでした。 |
1157 |
|
|
feature.pm の主な目的はユーザー定義サブルーチンとの衝突を避けることなので、 |
1158 |
|
|
C<continue> がこれに依存している意味はありません。 |
1159 |
|
|
|
1160 |
|
|
=head3 DTrace probes for interpreter phase change |
1161 |
|
|
|
1162 |
argrath |
1.2 |
(インタプリタフェーズ変更のための DTrace プローブ) |
1163 |
|
|
|
1164 |
argrath |
1.1 |
=begin original |
1165 |
|
|
|
1166 |
|
|
The C<phase-change> probes will fire when the interpreter's phase |
1167 |
|
|
changes, which tracks the C<${^GLOBAL_PHASE}> variable. C<arg0> is |
1168 |
|
|
the new phase name; C<arg1> is the old one. This is useful mostly |
1169 |
|
|
for limiting your instrumentation to one or more of: compile time, |
1170 |
|
|
run time, destruct time. |
1171 |
|
|
|
1172 |
|
|
=end original |
1173 |
|
|
|
1174 |
|
|
C<phase-change> プローブは、C<${^GLOBAL_PHASE}> 変数を |
1175 |
|
|
追跡することによって、インタプリタのフェーズが変わったときに起動されます。 |
1176 |
|
|
C<arg0> は新しいフェーズ名です; C<arg1> は古いフェーズ名です。 |
1177 |
|
|
これはコンパイル時、実行時、破壊時に装備を制限するために普通は有用です。 |
1178 |
|
|
|
1179 |
|
|
=head3 C<__FILE__()> Syntax |
1180 |
|
|
|
1181 |
argrath |
1.2 |
(C<__FILE__()> 文法) |
1182 |
|
|
|
1183 |
argrath |
1.1 |
=begin original |
1184 |
|
|
|
1185 |
|
|
The C<__FILE__>, C<__LINE__> and C<__PACKAGE__> tokens can now be written |
1186 |
|
|
with an empty pair of parentheses after them. This makes them parse the |
1187 |
|
|
same way as C<time>, C<fork> and other built-in functions. |
1188 |
|
|
|
1189 |
|
|
=end original |
1190 |
|
|
|
1191 |
|
|
C<__FILE__>, C<__LINE__>, C<__PACKAGE__> トークンは、後ろに空のかっこの |
1192 |
|
|
組を書けるようになりました。 |
1193 |
|
|
これにより C<time>, C<fork> やその他の組み込み関数と同じ方法で |
1194 |
|
|
パースできるようになります。 |
1195 |
|
|
|
1196 |
|
|
=head3 The C<\$> prototype accepts any scalar lvalue |
1197 |
|
|
|
1198 |
argrath |
1.7 |
(C<\$> プロトタイプは任意のスカラ左辺値を受け付けるように) |
1199 |
|
|
|
1200 |
argrath |
1.1 |
=begin original |
1201 |
|
|
|
1202 |
|
|
The C<\$> and C<\[$]> subroutine prototypes now accept any scalar lvalue |
1203 |
|
|
argument. Previously they only accepted scalars beginning with C<$> and |
1204 |
|
|
hash and array elements. This change makes them consistent with the way |
1205 |
|
|
the built-in C<read> and C<recv> functions (among others) parse their |
1206 |
|
|
arguments. This means that one can override the built-in functions with |
1207 |
|
|
custom subroutines that parse their arguments the same way. |
1208 |
|
|
|
1209 |
|
|
=end original |
1210 |
|
|
|
1211 |
|
|
C<\$> と C<\[$]> のサブルーチンプロトタイプは任意のスカラ左辺値引数を |
1212 |
|
|
受け付けるようになりました。 |
1213 |
|
|
以前は C<$> で始まるスカラとハッシュおよび配列の要素のみを |
1214 |
|
|
受け付けていました。 |
1215 |
argrath |
1.6 |
この変更により組み込みの C<read> 関数と C<recv> 関数が(特に)引数を |
1216 |
|
|
パースする方法と一貫性があるようになります。 |
1217 |
argrath |
1.5 |
これは、同じ方法で引数をパースするカスタムサブルーチンで組み込み関数を |
1218 |
|
|
オーバーライドできることを意味します。 |
1219 |
argrath |
1.1 |
|
1220 |
|
|
=head3 C<_> in subroutine prototypes |
1221 |
|
|
|
1222 |
argrath |
1.2 |
(サブルーチンプロトタイプの C<_>) |
1223 |
|
|
|
1224 |
argrath |
1.1 |
=begin original |
1225 |
|
|
|
1226 |
|
|
The C<_> character in subroutine prototypes is now allowed before C<@> or |
1227 |
|
|
C<%>. |
1228 |
|
|
|
1229 |
|
|
=end original |
1230 |
|
|
|
1231 |
|
|
サブルーチンプロトタイプの C<_> 文字は C<@> や C<%> の前に |
1232 |
|
|
使えるようになりました。 |
1233 |
|
|
|
1234 |
|
|
=head1 Security |
1235 |
|
|
|
1236 |
argrath |
1.2 |
(セキュリティ) |
1237 |
|
|
|
1238 |
argrath |
1.1 |
=head2 Use C<is_utf8_char_buf()> and not C<is_utf8_char()> |
1239 |
|
|
|
1240 |
argrath |
1.2 |
(C<is_utf8_char()> ではなく C<is_utf8_char_buf()> を使う) |
1241 |
|
|
|
1242 |
argrath |
1.1 |
=begin original |
1243 |
|
|
|
1244 |
|
|
The latter function is now deprecated because its API is insufficient to |
1245 |
|
|
guarantee that it doesn't read (up to 12 bytes in the worst case) beyond |
1246 |
|
|
the end of its input string. See |
1247 |
|
|
L<is_utf8_char_buf()|/Added is_utf8_char_buf()>. |
1248 |
|
|
|
1249 |
|
|
=end original |
1250 |
|
|
|
1251 |
|
|
後者の関数は、API が入力文字列の末尾を超えて(最悪の場合最大 12 バイト) |
1252 |
|
|
読み込まないことを保証できないので非推奨になりました。 |
1253 |
|
|
L<is_utf8_char_buf()|/Added is_utf8_char_buf()> を参照してください。 |
1254 |
|
|
|
1255 |
argrath |
1.7 |
=head2 Malformed UTF-8 input could cause attempts to read beyond the end of the buffer |
1256 |
|
|
|
1257 |
|
|
(不正な UTF-8 入力がバッファの末尾を超えて読み込もうとすることがある) |
1258 |
|
|
|
1259 |
|
|
=begin original |
1260 |
|
|
|
1261 |
|
|
Two new XS-accessible functions, C<utf8_to_uvchr_buf()> and |
1262 |
|
|
C<utf8_to_uvuni_buf()> are now available to prevent this, and the Perl |
1263 |
|
|
core has been converted to use them. |
1264 |
|
|
See L</Internal Changes>. |
1265 |
|
|
|
1266 |
|
|
=end original |
1267 |
|
|
|
1268 |
argrath |
1.14 |
二つの新しい XS アクセス可能な関数である C<utf8_to_uvchr_buf()> と |
1269 |
|
|
C<utf8_to_uvuni_buf()> がこれを避けるために利用可能となり、Perl コアは |
1270 |
|
|
これらを使うように変換されました。 |
1271 |
|
|
L</Internal Changes> を参照してください。 |
1272 |
argrath |
1.7 |
|
1273 |
argrath |
1.1 |
=head2 C<File::Glob::bsd_glob()> memory error with GLOB_ALTDIRFUNC (CVE-2011-2728). |
1274 |
|
|
|
1275 |
argrath |
1.2 |
(GLOB_ALTDIRFUNC での C<File::Glob::bsd_glob()> のメモリエラー (CVE-2011-2728)) |
1276 |
|
|
|
1277 |
argrath |
1.1 |
=begin original |
1278 |
|
|
|
1279 |
|
|
Calling C<File::Glob::bsd_glob> with the unsupported flag |
1280 |
|
|
GLOB_ALTDIRFUNC would cause an access violation / segfault. A Perl |
1281 |
|
|
program that accepts a flags value from an external source could expose |
1282 |
|
|
itself to denial of service or arbitrary code execution attacks. There |
1283 |
|
|
are no known exploits in the wild. The problem has been corrected by |
1284 |
|
|
explicitly disabling all unsupported flags and setting unused function |
1285 |
argrath |
1.16 |
pointers to null. Bug reported by Clément Lecigne. (5.14.2) |
1286 |
argrath |
1.1 |
|
1287 |
|
|
=end original |
1288 |
|
|
|
1289 |
|
|
未対応フラグ GLOB_ALTDIRFUNC 付きで C<File::Glob::bsd_glob> を呼び出すと |
1290 |
|
|
アクセス違反/セグメンテーションフォルトを引き起こすことがありました。 |
1291 |
|
|
外部ソースからフラグの値を受け付ける Perl プログラムはサービス不能攻撃や |
1292 |
|
|
任意コード実行攻撃に晒されるかもしれません。 |
1293 |
|
|
今のところ知られている攻撃はありません。 |
1294 |
|
|
この問題は、未対応フラグを明示的に無効にして、未使用関数のポインタを |
1295 |
|
|
null にすることで修正されました。 |
1296 |
argrath |
1.16 |
バグは ClE<eacute>ment Lecigne によって報告されました。(5.14.2) |
1297 |
argrath |
1.1 |
|
1298 |
|
|
=head2 Privileges are now set correctly when assigning to C<$(> |
1299 |
|
|
|
1300 |
argrath |
1.2 |
(C<$(> への代入時に権限が適切に設定されるように) |
1301 |
argrath |
1.1 |
|
1302 |
|
|
=begin original |
1303 |
|
|
|
1304 |
|
|
A hypothetical bug (probably non-exploitable in practice) due to the |
1305 |
|
|
incorrect setting of the effective group ID while setting C<$(> has been |
1306 |
|
|
fixed. The bug would only have affected systems that have C<setresgid()> |
1307 |
argrath |
1.16 |
but not C<setregid()>, but no such systems are known to exist. |
1308 |
argrath |
1.1 |
|
1309 |
|
|
=end original |
1310 |
|
|
|
1311 |
|
|
C<$(> の設定中の有効グループ ID の設定が正しくないことによる仮説上の |
1312 |
|
|
(おそらく実際には攻撃できない)バグが修正されました。 |
1313 |
|
|
このバグは C<setresgid()> はあるけれども C<setregid()> がないシステムにのみ |
1314 |
argrath |
1.16 |
影響を与えますが、そのようなシステムの存在は知られていません。 |
1315 |
argrath |
1.1 |
|
1316 |
argrath |
1.3 |
=head1 Deprecations |
1317 |
argrath |
1.2 |
|
1318 |
|
|
(非推奨) |
1319 |
argrath |
1.1 |
|
1320 |
|
|
=head2 Don't read the Unicode data base files in F<lib/unicore> |
1321 |
|
|
|
1322 |
argrath |
1.2 |
(F<lib/unicore> にある Unicode データベースファイルは読み込まない) |
1323 |
|
|
|
1324 |
argrath |
1.1 |
=begin original |
1325 |
|
|
|
1326 |
|
|
It is now deprecated to directly read the Unicode data base files. |
1327 |
|
|
These are stored in the F<lib/unicore> directory. Instead, you should |
1328 |
|
|
use the new functions in L<Unicode::UCD>. These provide a stable API, |
1329 |
|
|
and give complete information. |
1330 |
|
|
|
1331 |
|
|
=end original |
1332 |
|
|
|
1333 |
|
|
Unicode データベースファイルを直接読むのは非推奨になりました。 |
1334 |
|
|
これらは F<lib/unicore> ディレクトリに補完されています。 |
1335 |
|
|
代わりに、L<Unicode::UCD> の新しい関数を使うべきです。 |
1336 |
|
|
これらは安定した API を提供し、完全な情報を得られます。 |
1337 |
|
|
|
1338 |
|
|
=begin original |
1339 |
|
|
|
1340 |
|
|
Perl may at some point in the future change or remove the files. The |
1341 |
argrath |
1.16 |
file which applications were most likely to have used is |
1342 |
argrath |
1.1 |
F<lib/unicore/ToDigit.pl>. L<Unicode::UCD/prop_invmap()> can be used to |
1343 |
|
|
get at its data instead. |
1344 |
|
|
|
1345 |
|
|
=end original |
1346 |
|
|
|
1347 |
|
|
Perl は将来のいずれかの時点でファイルを変更または削除するかもしれません。 |
1348 |
argrath |
1.16 |
アプリケーションが一番使っていたであろうファイルは |
1349 |
argrath |
1.1 |
F<lib/unicore/ToDigit.pl> です。 |
1350 |
|
|
代わりにこのデータを得るために L<Unicode::UCD/prop_invmap()> が使えます。 |
1351 |
|
|
|
1352 |
argrath |
1.7 |
=head2 XS functions C<is_utf8_char()>, C<utf8_to_uvchr()> and |
1353 |
|
|
C<utf8_to_uvuni()> |
1354 |
|
|
|
1355 |
|
|
(XS 関数 C<is_utf8_char()>, C<utf8_to_uvchr()>, C<utf8_to_uvuni()>) |
1356 |
argrath |
1.1 |
|
1357 |
|
|
=begin original |
1358 |
|
|
|
1359 |
|
|
This function is deprecated because it could read beyond the end of the |
1360 |
argrath |
1.7 |
input string. Use the new L<is_utf8_char_buf()|/Added is_utf8_char_buf()>, |
1361 |
|
|
C<utf8_to_uvchr_buf()> and C<utf8_to_uvuni_buf()> instead. |
1362 |
argrath |
1.1 |
|
1363 |
|
|
=end original |
1364 |
|
|
|
1365 |
|
|
この関数は、入力文字列の末尾を超えて読み込むかもしれないので、 |
1366 |
|
|
非推奨になりました。 |
1367 |
argrath |
1.7 |
代わりに新しい L<is_utf8_char_buf()|/Added is_utf8_char_buf()>, |
1368 |
|
|
C<utf8_to_uvchr_buf()>, C<utf8_to_uvuni_buf()> を使ってください。 |
1369 |
argrath |
1.1 |
|
1370 |
|
|
=head1 Future Deprecations |
1371 |
|
|
|
1372 |
|
|
(将来の非推奨) |
1373 |
|
|
|
1374 |
|
|
=begin original |
1375 |
|
|
|
1376 |
|
|
This section serves as a notice of features that are I<likely> to be |
1377 |
|
|
removed or L<deprecated|perlpolicy/deprecated> in the next release of |
1378 |
|
|
perl (5.18.0). If your code depends on these features, you should |
1379 |
|
|
contact the Perl 5 Porters via the L<mailing |
1380 |
|
|
list|http://lists.perl.org/list/perl5-porters.html> or L<perlbug> to |
1381 |
|
|
explain your use case and inform the deprecation process. |
1382 |
|
|
|
1383 |
|
|
=end original |
1384 |
|
|
|
1385 |
|
|
この章は、次のリリースの perl (5.18.0) で I<おそらく> 削除されるか |
1386 |
|
|
L<非推奨|perlpolicy/deprecated> になる機能を示します。 |
1387 |
|
|
あなたのコードがこれらの機能に依存しているなら、あなたのユースケースを |
1388 |
|
|
説明して非推奨プロセスに知らせるために、 |
1389 |
|
|
L<メーリングリスト|http://lists.perl.org/list/perl5-porters.html> か |
1390 |
|
|
L<perlbug> で Perl 5 Porters に知らせるべきです。 |
1391 |
|
|
|
1392 |
|
|
=head2 Core Modules |
1393 |
|
|
|
1394 |
|
|
(コアモジュール) |
1395 |
|
|
|
1396 |
|
|
=begin original |
1397 |
|
|
|
1398 |
|
|
These modules may be marked as deprecated I<from the core>. This only |
1399 |
|
|
means that they will no longer be installed by default with the core |
1400 |
|
|
distribution, but will remain available on the CPAN. |
1401 |
|
|
|
1402 |
|
|
=end original |
1403 |
|
|
|
1404 |
|
|
これらのモジュールは I<コアからは> 非推奨としてマークされました。 |
1405 |
|
|
これはコア配布でデフォルトではインストールされなくなるというだけで、 |
1406 |
|
|
CPAN からは利用可能のままです。 |
1407 |
|
|
|
1408 |
|
|
=over |
1409 |
|
|
|
1410 |
|
|
=item * |
1411 |
|
|
|
1412 |
|
|
CPANPLUS |
1413 |
|
|
|
1414 |
|
|
=item * |
1415 |
|
|
|
1416 |
|
|
Filter::Simple |
1417 |
|
|
|
1418 |
|
|
=item * |
1419 |
|
|
|
1420 |
|
|
PerlIO::mmap |
1421 |
|
|
|
1422 |
|
|
=item * |
1423 |
|
|
|
1424 |
argrath |
1.16 |
Pod::LaTeX |
1425 |
|
|
|
1426 |
|
|
=item * |
1427 |
|
|
|
1428 |
|
|
Pod::Parser |
1429 |
argrath |
1.1 |
|
1430 |
|
|
=item * |
1431 |
|
|
|
1432 |
|
|
SelfLoader |
1433 |
|
|
|
1434 |
|
|
=item * |
1435 |
|
|
|
1436 |
|
|
Text::Soundex |
1437 |
|
|
|
1438 |
|
|
=item * |
1439 |
|
|
|
1440 |
|
|
Thread.pm |
1441 |
|
|
|
1442 |
|
|
=back |
1443 |
|
|
|
1444 |
|
|
=head2 Platforms with no supporting programmers: |
1445 |
|
|
|
1446 |
argrath |
1.2 |
(サポートするプログラマがいないプラットフォーム) |
1447 |
argrath |
1.1 |
|
1448 |
|
|
=begin original |
1449 |
|
|
|
1450 |
|
|
These platforms will probably have their |
1451 |
|
|
special build support removed during the |
1452 |
|
|
5.17.0 development series. |
1453 |
|
|
|
1454 |
|
|
=end original |
1455 |
|
|
|
1456 |
|
|
以下のプラットフォームはおそらく 5.17.0 開発シリーズの間に独自のビルド |
1457 |
|
|
サポートが削除されます。 |
1458 |
|
|
|
1459 |
|
|
=over |
1460 |
|
|
|
1461 |
|
|
=item * |
1462 |
|
|
|
1463 |
|
|
BeOS |
1464 |
|
|
|
1465 |
|
|
=item * |
1466 |
|
|
|
1467 |
|
|
djgpp |
1468 |
|
|
|
1469 |
|
|
=item * |
1470 |
|
|
|
1471 |
|
|
dgux |
1472 |
|
|
|
1473 |
|
|
=item * |
1474 |
|
|
|
1475 |
|
|
EPOC |
1476 |
|
|
|
1477 |
|
|
=item * |
1478 |
|
|
|
1479 |
|
|
MPE/iX |
1480 |
|
|
|
1481 |
|
|
=item * |
1482 |
|
|
|
1483 |
|
|
Rhapsody |
1484 |
|
|
|
1485 |
|
|
=item * |
1486 |
|
|
|
1487 |
|
|
UTS |
1488 |
|
|
|
1489 |
|
|
=item * |
1490 |
|
|
|
1491 |
|
|
VM/ESA |
1492 |
|
|
|
1493 |
|
|
=back |
1494 |
|
|
|
1495 |
|
|
=head2 Other Future Deprecations |
1496 |
|
|
|
1497 |
|
|
(その他の将来の非推奨) |
1498 |
|
|
|
1499 |
|
|
=over |
1500 |
|
|
|
1501 |
|
|
=item * |
1502 |
|
|
|
1503 |
|
|
=begin original |
1504 |
|
|
|
1505 |
|
|
Swapping of $< and $> |
1506 |
|
|
|
1507 |
|
|
=end original |
1508 |
|
|
|
1509 |
|
|
$< と $> の交換 |
1510 |
|
|
|
1511 |
argrath |
1.2 |
=begin original |
1512 |
|
|
|
1513 |
|
|
For more information about this future deprecation, see L<the relevant RT |
1514 |
|
|
ticket|https://rt.perl.org/rt3/Ticket/Display.html?id=96212>. |
1515 |
|
|
|
1516 |
|
|
=end original |
1517 |
|
|
|
1518 |
argrath |
1.4 |
この将来の非推奨に関するさらなる情報については、 |
1519 |
|
|
L<関連する RT チケット|https://rt.perl.org/rt3/Ticket/Display.html?id=96212> を |
1520 |
|
|
参照してください。 |
1521 |
argrath |
1.1 |
|
1522 |
|
|
=item * |
1523 |
|
|
|
1524 |
|
|
sfio, stdio |
1525 |
|
|
|
1526 |
argrath |
1.15 |
=begin original |
1527 |
|
|
|
1528 |
|
|
Perl supports being built without PerlIO proper, using a stdio or sfio |
1529 |
|
|
wrapper instead. A perl build like this will not support IO layers and |
1530 |
|
|
thus Unicode IO, making it rather handicapped. |
1531 |
|
|
|
1532 |
|
|
=end original |
1533 |
|
|
|
1534 |
|
|
Perl supports being built without PerlIO proper, using a stdio or sfio |
1535 |
|
|
wrapper instead. A perl build like this will not support IO layers and |
1536 |
|
|
thus Unicode IO, making it rather handicapped. |
1537 |
|
|
(TBT) |
1538 |
|
|
|
1539 |
|
|
=begin original |
1540 |
|
|
|
1541 |
|
|
PerlIO supports a C<stdio> layer if stdio use is desired, and similarly a |
1542 |
|
|
sfio layer could be produced. |
1543 |
|
|
|
1544 |
|
|
=end original |
1545 |
|
|
|
1546 |
|
|
PerlIO supports a C<stdio> layer if stdio use is desired, and similarly a |
1547 |
|
|
sfio layer could be produced. |
1548 |
|
|
(TBT) |
1549 |
|
|
|
1550 |
argrath |
1.1 |
=item * |
1551 |
|
|
|
1552 |
|
|
=begin original |
1553 |
|
|
|
1554 |
|
|
Unescaped literal C<< "{" >> in regular expressions. |
1555 |
|
|
|
1556 |
|
|
=end original |
1557 |
|
|
|
1558 |
|
|
正規表現中のエスケープされていないリテラルの C<< "{" >>。 |
1559 |
|
|
|
1560 |
|
|
=begin original |
1561 |
|
|
|
1562 |
|
|
It is planned starting in v5.20 to require a literal C<"{"> to be |
1563 |
|
|
escaped by, for example, preceding it with a backslash. In v5.18, a |
1564 |
|
|
deprecated warning message will be emitted for all such uses. Note that |
1565 |
|
|
this only affects patterns which are to match a literal C<"{">. Other |
1566 |
|
|
uses of this character, such as part of a quantifier or sequence like in |
1567 |
|
|
the ones below are completely unaffected: |
1568 |
|
|
|
1569 |
|
|
=end original |
1570 |
|
|
|
1571 |
|
|
v5.20 から、リテラルの C<"{"> は、例えばバックスラッシュを前置することで、 |
1572 |
|
|
エスケープする必要があるようにすることが計画されています。 |
1573 |
|
|
v5.18 では、このような使用全てで警告が出力されます。 |
1574 |
|
|
これはリテラルな C<"{"> にマッチングするパターンにのみ影響を与えることに |
1575 |
|
|
注意してください。 |
1576 |
argrath |
1.2 |
量指定子の一部や、以下のシーケンスのような、その他のこの文字の使用には |
1577 |
argrath |
1.1 |
全く影響を与えません: |
1578 |
|
|
|
1579 |
|
|
/foo{3,5}/ |
1580 |
|
|
/\p{Alphabetic}/ |
1581 |
|
|
/\N{DIGIT ZERO} |
1582 |
|
|
|
1583 |
|
|
=begin original |
1584 |
|
|
|
1585 |
|
|
The removal of this will allow extensions to pattern syntax, and better |
1586 |
|
|
error checking of existing syntax. See L<perlre/Quantifiers> for an |
1587 |
|
|
example. |
1588 |
|
|
|
1589 |
|
|
=end original |
1590 |
|
|
|
1591 |
|
|
この除去によって、パターン文法の拡張や、既にある文法のよりよいエラーチェックが |
1592 |
|
|
可能になります。 |
1593 |
|
|
例については L<perlre/Quantifiers> を参照してください。 |
1594 |
|
|
|
1595 |
argrath |
1.16 |
=item * |
1596 |
|
|
|
1597 |
|
|
=begin original |
1598 |
|
|
|
1599 |
|
|
Revamping C<< "\Q" >> semantics in double-quotish strings when combined with other escapes |
1600 |
|
|
|
1601 |
|
|
=end original |
1602 |
|
|
|
1603 |
|
|
Revamping C<< "\Q" >> semantics in double-quotish strings when combined with other escapes |
1604 |
|
|
(TBT) |
1605 |
|
|
|
1606 |
|
|
=begin original |
1607 |
|
|
|
1608 |
|
|
There are a number of bugs and inconsistencies involving combinations |
1609 |
|
|
of C<\Q> and excapes like C<\x>, C<\L>, etc., within a C<\Q...\E> pair. |
1610 |
|
|
These need to be fixed, and doing so will necessarily change current |
1611 |
|
|
behavior. The changes have not yet been settled. |
1612 |
|
|
|
1613 |
|
|
=end original |
1614 |
|
|
|
1615 |
|
|
There are a number of bugs and inconsistencies involving combinations |
1616 |
|
|
of C<\Q> and excapes like C<\x>, C<\L>, etc., within a C<\Q...\E> pair. |
1617 |
|
|
These need to be fixed, and doing so will necessarily change current |
1618 |
|
|
behavior. The changes have not yet been settled. |
1619 |
|
|
(TBT) |
1620 |
|
|
|
1621 |
argrath |
1.1 |
=back |
1622 |
|
|
|
1623 |
|
|
=head1 Incompatible Changes |
1624 |
|
|
|
1625 |
argrath |
1.2 |
(互換性のない変更) |
1626 |
|
|
|
1627 |
argrath |
1.1 |
=head2 Special blocks called in void context |
1628 |
|
|
|
1629 |
argrath |
1.2 |
(特殊ブロックは無効コンテキストで呼び出されるように) |
1630 |
|
|
|
1631 |
argrath |
1.1 |
=begin original |
1632 |
|
|
|
1633 |
|
|
Special blocks (C<BEGIN>, C<CHECK>, C<INIT>, C<UNITCHECK>, C<END>) are now |
1634 |
|
|
called in void context. This avoids wasteful copying of the result of the |
1635 |
|
|
last statement [perl #108794]. |
1636 |
|
|
|
1637 |
|
|
=end original |
1638 |
|
|
|
1639 |
|
|
特殊ブロック (C<BEGIN>, C<CHECK>, C<INIT>, C<UNITCHECK>, C<END>) は |
1640 |
|
|
無効コンテキストで呼び出されるようになりました。。 |
1641 |
|
|
これにより、最後の行の結果を無駄にコピーすることを防げます [perl #108794]。 |
1642 |
|
|
|
1643 |
|
|
=head2 The C<overloading> pragma and regexp objects |
1644 |
|
|
|
1645 |
argrath |
1.2 |
(C<overloading> プラグマと正規表現オブジェクト) |
1646 |
|
|
|
1647 |
argrath |
1.1 |
=begin original |
1648 |
|
|
|
1649 |
|
|
With C<no overloading>, regular expression objects returned by C<qr//> are |
1650 |
|
|
now stringified as "Regexp=REGEXP(0xbe600d)" instead of the regular |
1651 |
|
|
expression itself [perl #108780]. |
1652 |
|
|
|
1653 |
|
|
=end original |
1654 |
|
|
|
1655 |
|
|
C<no overloading> のとき、 C<qr//> によって返される正規表現オブジェクトは |
1656 |
|
|
正規表現自体ではなく、"Regexp=REGEXP(0xbe600d)" として |
1657 |
|
|
文字列化されるようになりました。 |
1658 |
|
|
|
1659 |
|
|
=head2 Two XS typemap Entries removed |
1660 |
|
|
|
1661 |
argrath |
1.2 |
(二つの XS typemap エントリを削除) |
1662 |
|
|
|
1663 |
argrath |
1.1 |
=begin original |
1664 |
|
|
|
1665 |
|
|
Two presumably unused XS typemap entries have been removed from the |
1666 |
|
|
core typemap: T_DATAUNIT and T_CALLBACK. If you are, against all odds, |
1667 |
argrath |
1.16 |
a user of these, please see the instructions on how to restore them |
1668 |
argrath |
1.1 |
in L<perlxstypemap>. |
1669 |
|
|
|
1670 |
|
|
=end original |
1671 |
|
|
|
1672 |
|
|
おそらく使われていない二つの XS typemap エントリ(T_DATAUNIT と T_CALLBACK)が |
1673 |
|
|
コア typemap から削除されました。 |
1674 |
|
|
もしあなたが、あらゆる予想を覆して、これらを使っているなら、 |
1675 |
|
|
これらを復活させる方法を記してある L<perlxstypemap> を参照してください。 |
1676 |
|
|
|
1677 |
|
|
=head2 Unicode 6.1 has incompatibilities with Unicode 6.0 |
1678 |
|
|
|
1679 |
argrath |
1.2 |
(Unicode 6.1 は Unicode 6.0 と互換性がない) |
1680 |
|
|
|
1681 |
argrath |
1.1 |
=begin original |
1682 |
|
|
|
1683 |
|
|
These are detailed in L</Supports (almost) Unicode 6.1> above. |
1684 |
|
|
You can compile this version of Perl to use Unicode 6.0. See |
1685 |
|
|
L<perlunicode/Hacking Perl to work on earlier Unicode versions (for very serious hackers only)>. |
1686 |
|
|
|
1687 |
|
|
=end original |
1688 |
|
|
|
1689 |
|
|
この詳細は上述の L</Supports (almost) Unicode 6.1> にあります。 |
1690 |
|
|
このバージョンの Perl を Unicode 6.0 を使ってコンパイルすることも出来ます。 |
1691 |
|
|
L<perlunicode/Hacking Perl to work on earlier Unicode versions (for very serious hackers only)> を |
1692 |
|
|
参照してください。 |
1693 |
|
|
|
1694 |
|
|
=head2 Borland compiler |
1695 |
|
|
|
1696 |
argrath |
1.2 |
(Borland コンパイラ) |
1697 |
|
|
|
1698 |
argrath |
1.1 |
=begin original |
1699 |
|
|
|
1700 |
|
|
All support for the Borland compiler has been dropped. The code had not |
1701 |
|
|
worked for a long time anyway. |
1702 |
|
|
|
1703 |
|
|
=end original |
1704 |
|
|
|
1705 |
|
|
Borland コンパイラ対応が全て削除されました。 |
1706 |
|
|
どちらにしろコードは長い間動作していませんでした。 |
1707 |
|
|
|
1708 |
|
|
=head2 Certain deprecated Unicode properties are no longer supported by default |
1709 |
|
|
|
1710 |
argrath |
1.2 |
(いくつかの非推奨の Unicode 特性がデフォルトではサポート外に) |
1711 |
|
|
|
1712 |
argrath |
1.1 |
=begin original |
1713 |
|
|
|
1714 |
|
|
Perl should never have exposed certain Unicode properties that are used |
1715 |
|
|
by Unicode internally and not meant to be publicly available. Use of |
1716 |
|
|
these has generated deprecated warning messages since Perl 5.12. The |
1717 |
|
|
removed properties are Other_Alphabetic, |
1718 |
|
|
Other_Default_Ignorable_Code_Point, Other_Grapheme_Extend, |
1719 |
|
|
Other_ID_Continue, Other_ID_Start, Other_Lowercase, Other_Math, and |
1720 |
|
|
Other_Uppercase. |
1721 |
|
|
|
1722 |
|
|
=end original |
1723 |
|
|
|
1724 |
|
|
Perl は、Unicode が内部で使って公開するつもりがないいくつかの Unicode 特性を |
1725 |
|
|
暴露するべきではありません。 |
1726 |
|
|
Perl 5.12 以降これらを使うと警告が出力されていました。 |
1727 |
|
|
削除された特性は、Other_Alphabetic, |
1728 |
|
|
Other_Default_Ignorable_Code_Point, Other_Grapheme_Extend, |
1729 |
|
|
Other_ID_Continue, Other_ID_Start, Other_Lowercase, Other_Math, |
1730 |
|
|
Other_Uppercase です。 |
1731 |
|
|
|
1732 |
|
|
=begin original |
1733 |
|
|
|
1734 |
|
|
Perl may be recompiled to include any or all of them; instructions are |
1735 |
|
|
given in |
1736 |
|
|
L<perluniprops/Unicode character properties that are NOT accepted by Perl>. |
1737 |
|
|
|
1738 |
|
|
=end original |
1739 |
|
|
|
1740 |
|
|
これらの一部または全部を含む形で Perl を再コンパイルすることもできます; |
1741 |
|
|
手順は |
1742 |
|
|
L<perluniprops/Unicode character properties that are NOT accepted by Perl> に |
1743 |
|
|
あります。 |
1744 |
|
|
|
1745 |
|
|
=head2 Dereferencing IO thingies as typeglobs |
1746 |
|
|
|
1747 |
argrath |
1.2 |
(IO 系のものを型グロブとしてデリファレンス) |
1748 |
|
|
|
1749 |
argrath |
1.1 |
=begin original |
1750 |
|
|
|
1751 |
|
|
The C<*{...}> operator, when passed a reference to an IO thingy (as in |
1752 |
|
|
C<*{*STDIN{IO}}>), creates a new typeglob containing just that IO object. |
1753 |
|
|
Previously, it would stringify as an empty string, but some operators would |
1754 |
|
|
treat it as undefined, producing an "uninitialized" warning. |
1755 |
|
|
Now it stringifies as __ANONIO__ [perl #96326]. |
1756 |
|
|
|
1757 |
|
|
=end original |
1758 |
|
|
|
1759 |
argrath |
1.3 |
C<*{...}> 演算子は、(C<*{*STDIN{IO}}> のような) IO 系へのリファレンスを |
1760 |
|
|
渡すと、IO オブジェクト自体を含む新しい型グロブを作成します。 |
1761 |
argrath |
1.1 |
以前は、空文字列として文字列化していましたが、一部の演算子はこれを |
1762 |
|
|
未定義として扱い、"uninitialized" 警告を出力していました。 |
1763 |
|
|
今では __ANONIO__ と文字列化されます [perl #96326]。 |
1764 |
|
|
|
1765 |
argrath |
1.7 |
=head2 User-defined case changing operations |
1766 |
argrath |
1.1 |
|
1767 |
argrath |
1.2 |
(ユーザー定義大文字変更操作) |
1768 |
|
|
|
1769 |
argrath |
1.1 |
=begin original |
1770 |
|
|
|
1771 |
|
|
This feature was deprecated in Perl 5.14, and has now been removed. |
1772 |
|
|
The CPAN module L<Unicode::Casing> provides better functionality without |
1773 |
|
|
the drawbacks that this feature had, as are detailed in the 5.14 |
1774 |
|
|
documentation: |
1775 |
|
|
L<http://perldoc.perl.org/5.14.0/perlunicode.html#User-Defined-Case-Mappings-%28for-serious-hackers-only%29> |
1776 |
|
|
|
1777 |
|
|
=end original |
1778 |
|
|
|
1779 |
|
|
この機能は Perl 5.14 で非推奨となり、今回削除されました。 |
1780 |
|
|
CPAN モジュール L<Unicode::Casing> は、5.14 の文書に詳細に記されている通り、 |
1781 |
|
|
この機能が持っていた欠点なしに、よりよい機能を提供します: |
1782 |
|
|
L<http://perldoc.perl.org/5.14.0/perlunicode.html#User-Defined-Case-Mappings-%28for-serious-hackers-only%29> |
1783 |
|
|
|
1784 |
|
|
=head2 XSUBs are now 'static' |
1785 |
|
|
|
1786 |
argrath |
1.2 |
(XSUB は 'static' に) |
1787 |
|
|
|
1788 |
argrath |
1.1 |
=begin original |
1789 |
|
|
|
1790 |
|
|
XSUB C functions are now 'static', that is, they are not visible from |
1791 |
|
|
outside the compilation unit. Users can use the new C<XS_EXTERNAL(name)> |
1792 |
|
|
and C<XS_INTERNAL(name)> macros to pick the desired linking behaviour. |
1793 |
|
|
The ordinary C<XS(name)> declaration for XSUBs will continue to declare |
1794 |
|
|
non-'static' XSUBs for compatibility, but the XS compiler, |
1795 |
argrath |
1.16 |
L<ExtUtils::ParseXS> (C<xsubpp>) will emit 'static' XSUBs by default. |
1796 |
|
|
L<ExtUtils::ParseXS>'s behaviour can be reconfigured from XS using the |
1797 |
argrath |
1.1 |
C<EXPORT_XSUB_SYMBOLS> keyword. See L<perlxs> for details. |
1798 |
|
|
|
1799 |
|
|
=end original |
1800 |
|
|
|
1801 |
|
|
XSUB C 関数は 'static' になりました; つまり、コンパイル単位の外側からは |
1802 |
|
|
見えなくなりました。 |
1803 |
|
|
ユーザーは求めるリンクの振る舞いを得るために新しい |
1804 |
|
|
C<XS_EXTERNAL(name)> マクロと C<XS_INTERNAL(name)> マクロを使えます。 |
1805 |
|
|
XSUB の通常の C<XS(name)> 宣言は互換性のために非 'static' な XSUB を |
1806 |
argrath |
1.16 |
宣言するままですが、XS コンパイラ L<ExtUtils::ParseXS> (C<xsubpp>) は |
1807 |
argrath |
1.1 |
デフォルトでは 'static' XSUB を出力します。 |
1808 |
argrath |
1.16 |
L<ExtUtils::ParseXS> の振る舞いは C<EXPORT_XSUB_SYMBOLS> キーワードを |
1809 |
argrath |
1.1 |
使った XS によって再設定できます。 |
1810 |
|
|
詳しくは L<perlxs> を参照してください。 |
1811 |
|
|
|
1812 |
|
|
=head2 Weakening read-only references |
1813 |
|
|
|
1814 |
argrath |
1.2 |
(読み込み専用の参照を弱くする) |
1815 |
|
|
|
1816 |
argrath |
1.1 |
=begin original |
1817 |
|
|
|
1818 |
|
|
Weakening read-only references is no longer permitted. It should never |
1819 |
|
|
have worked anyway, and in some cases could result in crashes. |
1820 |
|
|
|
1821 |
|
|
=end original |
1822 |
|
|
|
1823 |
|
|
読み込み専用の参照を弱くすることはできなくなりました。 |
1824 |
|
|
どちらにしても正しく動作しておらず、場合によってはクラッシュしていました。 |
1825 |
|
|
|
1826 |
|
|
=head2 Tying scalars that hold typeglobs |
1827 |
|
|
|
1828 |
argrath |
1.2 |
(型グロブを保持しているスカラの tie) |
1829 |
|
|
|
1830 |
argrath |
1.1 |
=begin original |
1831 |
|
|
|
1832 |
|
|
Attempting to tie a scalar after a typeglob was assigned to it would |
1833 |
|
|
instead tie the handle in the typeglob's IO slot. This meant that it was |
1834 |
|
|
impossible to tie the scalar itself. Similar problems affected C<tied> and |
1835 |
|
|
C<untie>: C<tied $scalar> would return false on a tied scalar if the last |
1836 |
|
|
thing returned was a typeglob, and C<untie $scalar> on such a tied scalar |
1837 |
|
|
would do nothing. |
1838 |
|
|
|
1839 |
|
|
=end original |
1840 |
|
|
|
1841 |
|
|
型グロブを代入された後のスカラを tie しようとすると、代わりに型グロブの |
1842 |
|
|
IO スロットにあるハンドルが tie されます。 |
1843 |
|
|
これは、スカラ自身を tie することが不可能になると言うことを意味します。 |
1844 |
|
|
似たような問題は C<tied> と C<untie> に影響を与えます: C<tied $scalar> は |
1845 |
|
|
最後に返されたものが型グロブの場合は tie されたスカラに偽を返し、 |
1846 |
|
|
そのような tie されたスカラに C<untie $scalar> しても何も起きません。 |
1847 |
|
|
|
1848 |
|
|
=begin original |
1849 |
|
|
|
1850 |
|
|
We fixed this problem before Perl 5.14.0, but it caused problems with some |
1851 |
|
|
CPAN modules, so we put in a deprecation cycle instead. |
1852 |
|
|
|
1853 |
|
|
=end original |
1854 |
|
|
|
1855 |
|
|
私たちはこの問題を Perl 5.14.0 の前に修正しましたが、これは一部の |
1856 |
|
|
CPAN モジュールに問題を引き起こすので、代わりに |
1857 |
|
|
非推奨サイクルに入れることにしました。 |
1858 |
|
|
|
1859 |
|
|
=begin original |
1860 |
|
|
|
1861 |
|
|
Now the deprecation has been removed and this bug has been fixed. So |
1862 |
|
|
C<tie $scalar> will always tie the scalar, not the handle it holds. To tie |
1863 |
|
|
the handle, use C<tie *$scalar> (with an explicit asterisk). The same |
1864 |
|
|
applies to C<tied *$scalar> and C<untie *$scalar>. |
1865 |
|
|
|
1866 |
|
|
=end original |
1867 |
|
|
|
1868 |
|
|
今回非推奨は削除され、バグは修正されました。 |
1869 |
|
|
それで C<tie $scalar> は、スカラが保存しているハンドルではなく、スカラ自身を |
1870 |
|
|
tie します。 |
1871 |
|
|
ハンドルを tie するには、C<tie *$scalar> を(明示的なアスタリスク付きで) |
1872 |
|
|
使ってください。 |
1873 |
|
|
同じ内容は C<tied *$scalar> と C<untie *$scalar> にも適用されます。 |
1874 |
|
|
|
1875 |
|
|
=head2 IPC::Open3 no longer provides C<xfork()>, C<xclose_on_exec()> |
1876 |
|
|
and C<xpipe_anon()> |
1877 |
|
|
|
1878 |
argrath |
1.2 |
(IPC::Open3 は C<xfork()>, C<xclose_on_exec()>, C<xpipe_anon()> を提供しません) |
1879 |
|
|
|
1880 |
|
|
=begin original |
1881 |
|
|
|
1882 |
argrath |
1.1 |
All three functions were private, undocumented and unexported. They do |
1883 |
|
|
not appear to be used by any code on CPAN. Two have been inlined and one |
1884 |
|
|
deleted entirely. |
1885 |
|
|
|
1886 |
argrath |
1.2 |
=end original |
1887 |
|
|
|
1888 |
|
|
これら三つの関数はプライベートなもので文書化されておらずエクスポートも |
1889 |
|
|
されていません。 |
1890 |
|
|
これらは CPAN のどのコードからも使われていません。 |
1891 |
|
|
二つはインライン化され、一つは完全に削除されました。 |
1892 |
|
|
|
1893 |
argrath |
1.1 |
=head2 C<$$> no longer caches PID |
1894 |
|
|
|
1895 |
argrath |
1.2 |
(C<$$> は PID をキャッシュしません) |
1896 |
|
|
|
1897 |
|
|
=begin original |
1898 |
|
|
|
1899 |
argrath |
1.1 |
Previously, if one called fork(3) from C, Perl's |
1900 |
|
|
notion of C<$$> could go out of sync with what getpid() returns. By always |
1901 |
|
|
fetching the value of C<$$> via getpid(), this potential bug is eliminated. |
1902 |
|
|
Code that depends on the caching behavior will break. As described in |
1903 |
|
|
L<Core Enhancements|/C<$$> can be assigned to>, |
1904 |
|
|
C<$$> is now writable, but it will be reset during a |
1905 |
|
|
fork. |
1906 |
|
|
|
1907 |
argrath |
1.2 |
=end original |
1908 |
|
|
|
1909 |
|
|
以前は、C から fork(3) を呼び出すと、Perl の C<$$> の概念は getpid() が |
1910 |
|
|
返すものと同期しなくなることがありました。 |
1911 |
|
|
常に getpid() 経由で C<$$> の値を取得することで、この潜在的なバグは |
1912 |
|
|
修正されました。 |
1913 |
|
|
キャッシュする振る舞いに依存しているコードは動かなくなります。 |
1914 |
|
|
L<Core Enhancements|/C<$$> can be assigned to> で記述したように、 |
1915 |
|
|
C<$$> は書き込み可能になりましたが、fork 中はリセットされます。 |
1916 |
|
|
|
1917 |
argrath |
1.1 |
=head2 C<$$> and C<getppid()> no longer emulate POSIX semantics under LinuxThreads |
1918 |
|
|
|
1919 |
argrath |
1.4 |
(C<$$> と C<getppid()> は LinuxThreads のもとで POSIX の意味論をエミュレートしません) |
1920 |
|
|
|
1921 |
|
|
=begin original |
1922 |
|
|
|
1923 |
argrath |
1.1 |
The POSIX emulation of C<$$> and C<getppid()> under the obsolete |
1924 |
|
|
LinuxThreads implementation has been removed. |
1925 |
|
|
This only impacts users of Linux 2.4 and |
1926 |
|
|
users of Debian GNU/kFreeBSD up to and including 6.0, not the vast |
1927 |
|
|
majority of Linux installations that use NPTL threads. |
1928 |
|
|
|
1929 |
argrath |
1.4 |
=end original |
1930 |
|
|
|
1931 |
|
|
古い LinuxThreads 実装のもとでの C<$$> と C<getppid()> の POSIX |
1932 |
|
|
エミュレーションは削除されました。 |
1933 |
|
|
これは Linux 2.4 のユーザーとバージョン 6.0 までの Debian GNU/kFreeBSD の |
1934 |
|
|
ユーザーにのみ影響があり、NPTL スレッドを使っている圧倒的多数の |
1935 |
|
|
Linux インストールには影響はありません。 |
1936 |
|
|
|
1937 |
|
|
=begin original |
1938 |
|
|
|
1939 |
argrath |
1.1 |
This means that C<getppid()>, like C<$$>, is now always guaranteed to |
1940 |
|
|
return the OS's idea of the current state of the process, not perl's |
1941 |
|
|
cached version of it. |
1942 |
|
|
|
1943 |
argrath |
1.4 |
=end original |
1944 |
|
|
|
1945 |
|
|
これは、C<getppid()> は C<$$> と同様に、perl がキャッシュしたものではなく |
1946 |
|
|
OS が考えているプロセスの現在の状態を常に返すと言うことを意味まします。 |
1947 |
|
|
|
1948 |
|
|
=begin original |
1949 |
|
|
|
1950 |
argrath |
1.1 |
See the documentation for L<$$|perlvar/$$> for details. |
1951 |
|
|
|
1952 |
argrath |
1.4 |
=end original |
1953 |
|
|
|
1954 |
|
|
詳しくは L<$$|perlvar/$$> の文書を参照してください。 |
1955 |
|
|
|
1956 |
argrath |
1.1 |
=head2 C<< $< >>, C<< $> >>, C<$(> and C<$)> are no longer cached |
1957 |
|
|
|
1958 |
argrath |
1.4 |
(C<< $< >>, C<< $> >>, C<$(>, C<$)> はキャッシュされません) |
1959 |
|
|
|
1960 |
|
|
=begin original |
1961 |
|
|
|
1962 |
argrath |
1.1 |
Similarly to the changes to C<$$> and C<getppid()>, the internal |
1963 |
|
|
caching of C<< $< >>, C<< $> >>, C<$(> and C<$)> has been removed. |
1964 |
|
|
|
1965 |
argrath |
1.4 |
=end original |
1966 |
|
|
|
1967 |
|
|
C<$$> および C<getppid()> の変更と同様に C<< $< >>, C<< $> >>, C<$(>, |
1968 |
|
|
C<$)> の内部キャッシュも削除されました。 |
1969 |
|
|
|
1970 |
|
|
=begin original |
1971 |
|
|
|
1972 |
|
|
When we cached these values our idea of what they were would drift out |
1973 |
|
|
of sync with reality if someone (e.g., someone embedding perl) called |
1974 |
|
|
C<sete?[ug]id()> without updating C<PL_e?[ug]id>. Having to deal with |
1975 |
|
|
this complexity wasn't worth it given how cheap the C<gete?[ug]id()> |
1976 |
|
|
system call is. |
1977 |
|
|
|
1978 |
|
|
=end original |
1979 |
|
|
|
1980 |
argrath |
1.1 |
When we cached these values our idea of what they were would drift out |
1981 |
|
|
of sync with reality if someone (e.g., someone embedding perl) called |
1982 |
argrath |
1.5 |
C<sete?[ug]id()> without updating C<PL_e?[ug]id>. |
1983 |
|
|
この複雑性は C<gete?[ug]id()> の呼び出しコストの低さを考えると割に |
1984 |
|
|
合いませんでした。 |
1985 |
argrath |
1.4 |
(TBT) |
1986 |
|
|
|
1987 |
|
|
=begin original |
1988 |
argrath |
1.1 |
|
1989 |
|
|
This change will break a handful of CPAN modules that use the XS-level |
1990 |
|
|
C<PL_uid>, C<PL_gid>, C<PL_euid> or C<PL_egid> variables. |
1991 |
|
|
|
1992 |
argrath |
1.4 |
=end original |
1993 |
|
|
|
1994 |
|
|
この変更により XS レベルの C<PL_uid>, C<PL_gid>, C<PL_euid>, |
1995 |
|
|
C<PL_egid> 変数を使っている一握りの CPAN モジュールが動かなくなります。 |
1996 |
|
|
|
1997 |
|
|
=begin original |
1998 |
|
|
|
1999 |
argrath |
1.1 |
The fix for those breakages is to use C<PerlProc_gete?[ug]id()> to |
2000 |
|
|
retrieve them (e.g. C<PerlProc_getuid()>), and not to assign to |
2001 |
|
|
C<PL_e?[ug]id> if you change the UID/GID/EUID/EGID. There is no longer |
2002 |
|
|
any need to do so since perl will always retrieve the up-to-date |
2003 |
|
|
version of those values from the OS. |
2004 |
|
|
|
2005 |
argrath |
1.4 |
=end original |
2006 |
|
|
|
2007 |
|
|
これを修正するには、値を得るのに (C<PerlProc_getuid()> のような) |
2008 |
|
|
C<PerlProc_gete?[ug]id()> を使って、もし UID/GID/EUID/EGID を変更するなら |
2009 |
|
|
C<PL_e?[ug]id> に代入しないことです。 |
2010 |
|
|
perl はこれらの値を常に OS から最新の値を取るようになったので、 |
2011 |
|
|
このようにする必要性はなくなっています。 |
2012 |
|
|
|
2013 |
argrath |
1.1 |
=head2 Which Non-ASCII characters get quoted by C<quotemeta> and C<\Q> has changed |
2014 |
|
|
|
2015 |
argrath |
1.7 |
(C<quotemeta> と C<\Q> でクォートされる非 ASCII 文字の変更) |
2016 |
argrath |
1.4 |
|
2017 |
|
|
=begin original |
2018 |
|
|
|
2019 |
argrath |
1.1 |
This is unlikely to result in a real problem, as Perl does not attach |
2020 |
|
|
special meaning to any non-ASCII character, so it is currently |
2021 |
|
|
irrelevant which are quoted or not. This change fixes bug [perl #77654] and |
2022 |
|
|
bring Perl's behavior more into line with Unicode's recommendations. |
2023 |
|
|
See L<perlfunc/quotemeta>. |
2024 |
|
|
|
2025 |
argrath |
1.4 |
=end original |
2026 |
|
|
|
2027 |
|
|
Perl は非 ASCII 文字に特別な意味を割り振っていないために、これが実際の |
2028 |
|
|
問題になるとは考えにくいので、今のところクォートされているかどうかは |
2029 |
|
|
無関係です。 |
2030 |
|
|
この変更は [perl #77654] のバグを修正して、Perl の振る舞いを Unicode の |
2031 |
|
|
要求により近いものにします。 |
2032 |
|
|
L<perlfunc/quotemeta> を参照してください。 |
2033 |
|
|
|
2034 |
argrath |
1.1 |
=head1 Performance Enhancements |
2035 |
|
|
|
2036 |
argrath |
1.6 |
(性能改善) |
2037 |
|
|
|
2038 |
argrath |
1.1 |
=over |
2039 |
|
|
|
2040 |
|
|
=item * |
2041 |
|
|
|
2042 |
argrath |
1.6 |
=begin original |
2043 |
|
|
|
2044 |
argrath |
1.1 |
Improved performance for Unicode properties in regular expressions |
2045 |
|
|
|
2046 |
argrath |
1.6 |
=end original |
2047 |
|
|
|
2048 |
|
|
正規表現中の Unicode 特性の性能改善 |
2049 |
|
|
|
2050 |
argrath |
1.1 |
=for comment Can this be compacted some? -- rjbs, 2012-02-20 |
2051 |
|
|
|
2052 |
argrath |
1.16 |
=begin original |
2053 |
|
|
|
2054 |
|
|
Matching a code point against a Unicode property is now done via a |
2055 |
|
|
binary search instead of linear. This means for example that the worst |
2056 |
|
|
case for a 1000 item property is 10 probes instead of 1000. This |
2057 |
|
|
inefficiency has been compensated for in the past by permanently storing |
2058 |
|
|
in a hash the results of a given probe plus the results for the adjacent |
2059 |
|
|
64 code points, under the theory that near-by code points are likely to |
2060 |
|
|
be searched for. A separate hash was used for each mention of a Unicode |
2061 |
|
|
property in each regular expression. Thus, C<qr/\p{foo}abc\p{foo}/> |
2062 |
|
|
would generate two hashes. Any probes in one instance would be unknown |
2063 |
|
|
to the other, and the hashes could expand separately to be quite large |
2064 |
|
|
if the regular expression were used on many different widely-separated |
2065 |
|
|
code points. |
2066 |
|
|
Now, however, there is just one hash shared by all instances of a given |
2067 |
|
|
property. This means that if C<\p{foo}> is matched against "A" in one |
2068 |
|
|
regular expression in a thread, the result will be known immediately to |
2069 |
|
|
all regular expressions, and the relentless march of using up memory is |
2070 |
|
|
slowed considerably. |
2071 |
|
|
|
2072 |
|
|
=end original |
2073 |
|
|
|
2074 |
argrath |
1.1 |
Matching a code point against a Unicode property is now done via a |
2075 |
|
|
binary search instead of linear. This means for example that the worst |
2076 |
|
|
case for a 1000 item property is 10 probes instead of 1000. This |
2077 |
|
|
inefficiency has been compensated for in the past by permanently storing |
2078 |
|
|
in a hash the results of a given probe plus the results for the adjacent |
2079 |
|
|
64 code points, under the theory that near-by code points are likely to |
2080 |
|
|
be searched for. A separate hash was used for each mention of a Unicode |
2081 |
|
|
property in each regular expression. Thus, C<qr/\p{foo}abc\p{foo}/> |
2082 |
|
|
would generate two hashes. Any probes in one instance would be unknown |
2083 |
|
|
to the other, and the hashes could expand separately to be quite large |
2084 |
|
|
if the regular expression were used on many different widely-separated |
2085 |
argrath |
1.16 |
code points. |
2086 |
argrath |
1.1 |
Now, however, there is just one hash shared by all instances of a given |
2087 |
|
|
property. This means that if C<\p{foo}> is matched against "A" in one |
2088 |
|
|
regular expression in a thread, the result will be known immediately to |
2089 |
|
|
all regular expressions, and the relentless march of using up memory is |
2090 |
|
|
slowed considerably. |
2091 |
argrath |
1.16 |
(TBT) |
2092 |
argrath |
1.1 |
|
2093 |
|
|
=item * |
2094 |
|
|
|
2095 |
argrath |
1.6 |
=begin original |
2096 |
|
|
|
2097 |
argrath |
1.1 |
Version declarations with the C<use> keyword (e.g., C<use 5.012>) are now |
2098 |
|
|
faster, as they enable features without loading F<feature.pm>. |
2099 |
|
|
|
2100 |
argrath |
1.6 |
=end original |
2101 |
|
|
|
2102 |
|
|
(C<use 5.012> のような)C<use> キーワードのバージョン宣言は、 |
2103 |
|
|
F<feature.pm> を読み込むことなく機能を有効にするので、より |
2104 |
|
|
速くなりました。 |
2105 |
|
|
|
2106 |
argrath |
1.1 |
=item * |
2107 |
|
|
|
2108 |
argrath |
1.6 |
=begin original |
2109 |
|
|
|
2110 |
argrath |
1.1 |
C<local $_> is faster now, as it no longer iterates through magic that it |
2111 |
|
|
is not going to copy anyway. |
2112 |
|
|
|
2113 |
argrath |
1.6 |
=end original |
2114 |
|
|
|
2115 |
|
|
結局コピーされないマジックを反復しなくなったので、C<local $_> は |
2116 |
|
|
早くなりました。 |
2117 |
|
|
|
2118 |
argrath |
1.1 |
=item * |
2119 |
|
|
|
2120 |
argrath |
1.6 |
=begin original |
2121 |
|
|
|
2122 |
argrath |
1.1 |
Perl 5.12.0 sped up the destruction of objects whose classes define |
2123 |
|
|
empty C<DESTROY> methods (to prevent autoloading), by simply not |
2124 |
|
|
calling such empty methods. This release takes this optimisation a |
2125 |
|
|
step further, by not calling any C<DESTROY> method that begins with a |
2126 |
|
|
C<return> statement. This can be useful for destructors that are only |
2127 |
|
|
used for debugging: |
2128 |
|
|
|
2129 |
argrath |
1.6 |
=end original |
2130 |
|
|
|
2131 |
|
|
Perl 5.12.0 は(オートロードを防ぐために) 空の C<DESTROY> メソッドを |
2132 |
|
|
定義しているクラスのオブジェクトを破壊するときに、単にそのような |
2133 |
|
|
空メソッドを呼ばないようにすることで高速化しました。 |
2134 |
|
|
このリリースはこの最適化をさらに進めて、C<return> 文で始まる |
2135 |
|
|
全ての C<DESTROY> メソッドを呼び出さなくなりました。 |
2136 |
|
|
これはデストラクタがデバッグのためだけに使われている場合に有用です: |
2137 |
|
|
|
2138 |
argrath |
1.1 |
use constant DEBUG => 1; |
2139 |
|
|
sub DESTROY { return unless DEBUG; ... } |
2140 |
|
|
|
2141 |
argrath |
1.6 |
=begin original |
2142 |
|
|
|
2143 |
argrath |
1.1 |
Constant-folding will reduce the first statement to C<return;> if DEBUG |
2144 |
|
|
is set to 0, triggering this optimisation. |
2145 |
|
|
|
2146 |
argrath |
1.6 |
=end original |
2147 |
|
|
|
2148 |
|
|
DEBUG が 0 にセットされ、最適化が有効になっているなら、 |
2149 |
|
|
定数の畳み込みが C<return;> への最初の文に制限されるようになります。 |
2150 |
|
|
|
2151 |
argrath |
1.1 |
=item * |
2152 |
|
|
|
2153 |
argrath |
1.6 |
=begin original |
2154 |
|
|
|
2155 |
argrath |
1.1 |
Assigning to a variable that holds a typeglob or copy-on-write scalar |
2156 |
|
|
is now much faster. Previously the typeglob would be stringified or |
2157 |
|
|
the copy-on-write scalar would be copied before being clobbered. |
2158 |
|
|
|
2159 |
argrath |
1.6 |
=end original |
2160 |
|
|
|
2161 |
|
|
型グロブを補完している変数やコピーオンライトスカラ変数への代入は |
2162 |
|
|
とても速くなりました。 |
2163 |
|
|
以前は型グロブは文字列化され、、コピーオンライトスカラ変数は上書きされる |
2164 |
|
|
前にコピーされていました。 |
2165 |
|
|
|
2166 |
argrath |
1.1 |
=item * |
2167 |
|
|
|
2168 |
argrath |
1.6 |
=begin original |
2169 |
|
|
|
2170 |
argrath |
1.1 |
Assignment to C<substr> in void context is now more than twice its |
2171 |
|
|
previous speed. Instead of creating and returning a special lvalue |
2172 |
|
|
scalar that is then assigned to, C<substr> modifies the original string |
2173 |
|
|
itself. |
2174 |
|
|
|
2175 |
argrath |
1.6 |
=end original |
2176 |
|
|
|
2177 |
|
|
無効コンテキストでの C<substr> への代入は以前より倍以上速くなりました。 |
2178 |
|
|
後で代入される特殊左辺値を作って返すのではなく、C<substr> 自身が |
2179 |
|
|
元の文字列を変更します。 |
2180 |
|
|
|
2181 |
argrath |
1.1 |
=item * |
2182 |
|
|
|
2183 |
argrath |
1.6 |
=begin original |
2184 |
|
|
|
2185 |
argrath |
1.1 |
C<substr> no longer calculates a value to return when called in void |
2186 |
|
|
context. |
2187 |
|
|
|
2188 |
argrath |
1.6 |
=end original |
2189 |
|
|
|
2190 |
|
|
C<substr> は、無効コンテキストで呼び出された場合は返す値を |
2191 |
|
|
計算しなくなりました。 |
2192 |
|
|
|
2193 |
argrath |
1.1 |
=item * |
2194 |
|
|
|
2195 |
argrath |
1.6 |
=begin original |
2196 |
|
|
|
2197 |
argrath |
1.1 |
Due to changes in L<File::Glob>, Perl's C<glob> function and its C<< |
2198 |
|
|
<...> >> equivalent are now much faster. The splitting of the pattern |
2199 |
|
|
into words has been rewritten in C, resulting in speed-ups of 20% in |
2200 |
|
|
some cases. |
2201 |
|
|
|
2202 |
argrath |
1.6 |
=end original |
2203 |
|
|
|
2204 |
|
|
L<File::Glob> の変更により、Perl の C<glob> 関数および、等価な |
2205 |
|
|
C<< <...> >> はとても速くなりました。 |
2206 |
|
|
パターンから単語への分割は C で書き直されたので、場合によっては 20% |
2207 |
|
|
高速化しました。 |
2208 |
|
|
|
2209 |
|
|
=begin original |
2210 |
|
|
|
2211 |
argrath |
1.1 |
This does not affect C<glob> on VMS, as it does not use File::Glob. |
2212 |
|
|
|
2213 |
argrath |
1.6 |
=end original |
2214 |
|
|
|
2215 |
|
|
これは VMS の C<glob> には影響を与えません; File::Glob を |
2216 |
|
|
使わないからです。 |
2217 |
|
|
|
2218 |
argrath |
1.1 |
=item * |
2219 |
|
|
|
2220 |
argrath |
1.6 |
=begin original |
2221 |
|
|
|
2222 |
argrath |
1.1 |
The short-circuiting operators C<&&>, C<||>, and C<//>, when chained |
2223 |
|
|
(such as C<$a || $b || $c>), are now considerably faster to short-circuit, |
2224 |
|
|
due to reduced optree traversal. |
2225 |
|
|
|
2226 |
argrath |
1.6 |
=end original |
2227 |
|
|
|
2228 |
|
|
短絡演算子 C<&&>, C<||>, and C<//> は (C<$a || $b || $c> のように) |
2229 |
|
|
連結されたとき、大幅に速くなりました; 構文木をたどる量が減少したからです。 |
2230 |
|
|
|
2231 |
argrath |
1.1 |
=item * |
2232 |
|
|
|
2233 |
argrath |
1.6 |
=begin original |
2234 |
|
|
|
2235 |
argrath |
1.1 |
The implementation of C<s///r> makes one fewer copy of the scalar's value. |
2236 |
|
|
|
2237 |
argrath |
1.6 |
=end original |
2238 |
|
|
|
2239 |
|
|
C<s///r> の実装のスカラ値のコピーが一回減りました。 |
2240 |
|
|
|
2241 |
argrath |
1.1 |
=item * |
2242 |
|
|
|
2243 |
argrath |
1.6 |
=begin original |
2244 |
|
|
|
2245 |
argrath |
1.1 |
Recursive calls to lvalue subroutines in lvalue scalar context use less |
2246 |
|
|
memory. |
2247 |
|
|
|
2248 |
argrath |
1.6 |
=end original |
2249 |
|
|
|
2250 |
|
|
左辺値スカラコンテキストでの左辺サブルーチンの再帰呼び出しのメモリ消費が |
2251 |
|
|
少なくなりました。 |
2252 |
|
|
|
2253 |
argrath |
1.1 |
=back |
2254 |
|
|
|
2255 |
|
|
=head1 Modules and Pragmata |
2256 |
|
|
|
2257 |
argrath |
1.6 |
(モジュールとプラグマ) |
2258 |
|
|
|
2259 |
argrath |
1.1 |
=head2 Deprecated Modules |
2260 |
|
|
|
2261 |
argrath |
1.6 |
(非推奨のモジュール) |
2262 |
|
|
|
2263 |
argrath |
1.1 |
=over |
2264 |
|
|
|
2265 |
|
|
=item L<Version::Requirements> |
2266 |
|
|
|
2267 |
argrath |
1.6 |
=begin original |
2268 |
|
|
|
2269 |
argrath |
1.2 |
Version::Requirements is now DEPRECATED, use L<CPAN::Meta::Requirements>, |
2270 |
argrath |
1.1 |
which is a drop-in replacement. It will be deleted from perl.git blead |
2271 |
|
|
in v5.17.0. |
2272 |
|
|
|
2273 |
argrath |
1.6 |
=end original |
2274 |
|
|
|
2275 |
|
|
Version::Requirements は非推奨となりました; 差し込み式の代替品である |
2276 |
|
|
L<CPAN::Meta::Requirements> を使ってください。 |
2277 |
|
|
これは v5.17.0 の perl.git blead で削除されます。 |
2278 |
|
|
|
2279 |
argrath |
1.1 |
=back |
2280 |
|
|
|
2281 |
|
|
=head2 New Modules and Pragmata |
2282 |
|
|
|
2283 |
argrath |
1.6 |
(新しいモジュールとプラグマ) |
2284 |
|
|
|
2285 |
argrath |
1.1 |
=over 4 |
2286 |
|
|
|
2287 |
|
|
=item * |
2288 |
|
|
|
2289 |
argrath |
1.6 |
=begin original |
2290 |
|
|
|
2291 |
argrath |
1.1 |
L<arybase> -- this new module implements the C<$[> variable. |
2292 |
|
|
|
2293 |
argrath |
1.6 |
=end original |
2294 |
|
|
|
2295 |
|
|
L<arybase> -- これは C<$[> 変数を実装する新しいモジュールです。 |
2296 |
|
|
|
2297 |
argrath |
1.1 |
=item * |
2298 |
|
|
|
2299 |
argrath |
1.6 |
=begin original |
2300 |
|
|
|
2301 |
argrath |
1.16 |
L<PerlIO::mmap> 0.010 has been added to the Perl core. |
2302 |
argrath |
1.1 |
|
2303 |
argrath |
1.6 |
=end original |
2304 |
|
|
|
2305 |
argrath |
1.16 |
L<PerlIO::mmap> 0.010 が Perl コアに追加されました。 |
2306 |
argrath |
1.6 |
|
2307 |
|
|
=begin original |
2308 |
|
|
|
2309 |
argrath |
1.1 |
The C<mmap> PerlIO layer is no longer implemented by perl itself, but has |
2310 |
|
|
been moved out into the new L<PerlIO::mmap> module. |
2311 |
|
|
|
2312 |
argrath |
1.6 |
=end original |
2313 |
|
|
|
2314 |
|
|
C<mmap> PerlIO 層は perl 自身では実装されなくなり、新しい |
2315 |
|
|
L<PerlIO::mmap> モジュールに外出しされました。 |
2316 |
|
|
|
2317 |
argrath |
1.1 |
=back |
2318 |
|
|
|
2319 |
|
|
=head2 Updated Modules and Pragmata |
2320 |
|
|
|
2321 |
argrath |
1.6 |
(更新されたモジュールとプラグマ) |
2322 |
|
|
|
2323 |
argrath |
1.16 |
=begin original |
2324 |
|
|
|
2325 |
|
|
This is only an overview of selected module updates. For a complete list of |
2326 |
|
|
updates, run: |
2327 |
|
|
|
2328 |
|
|
=end original |
2329 |
|
|
|
2330 |
|
|
This is only an overview of selected module updates. For a complete list of |
2331 |
|
|
updates, run: |
2332 |
|
|
(TBT) |
2333 |
|
|
|
2334 |
|
|
$ corelist --diff 5.14.0 5.16.0 |
2335 |
|
|
|
2336 |
|
|
=begin original |
2337 |
|
|
|
2338 |
|
|
You can substitute your favorite version in place of 5.14.0, too. |
2339 |
|
|
|
2340 |
|
|
=end original |
2341 |
|
|
|
2342 |
|
|
You can substitute your favorite version in place of 5.14.0, too. |
2343 |
|
|
(TBT) |
2344 |
|
|
|
2345 |
|
|
=over 4 |
2346 |
|
|
|
2347 |
|
|
=item * |
2348 |
|
|
|
2349 |
|
|
L<Archive::Extract> has been upgraded from version 0.48 to 0.58. |
2350 |
|
|
|
2351 |
|
|
Includes a fix for FreeBSD to only use C<unzip> if it is located in |
2352 |
|
|
C</usr/local/bin>, as FreeBSD 9.0 will ship with a limited C<unzip> in |
2353 |
|
|
C</usr/bin>. |
2354 |
|
|
|
2355 |
|
|
=item * |
2356 |
|
|
|
2357 |
|
|
L<Archive::Tar> has been upgraded from version 1.76 to 1.82. |
2358 |
|
|
|
2359 |
|
|
Adjustments to handle files >8gb (>0777777777777 octal) and a feature |
2360 |
|
|
to return the MD5SUM of files in the archive. |
2361 |
|
|
|
2362 |
|
|
=item * |
2363 |
|
|
|
2364 |
|
|
L<base> has been upgraded from version 2.16 to 2.18. |
2365 |
|
|
|
2366 |
|
|
C<base> no longer sets a module's C<$VERSION> to "-1" when a module it |
2367 |
|
|
loads does not define a C<$VERSION>. This change has been made because |
2368 |
|
|
"-1" is not a valid version number under the new "lax" criteria used |
2369 |
|
|
internally by C<UNIVERSAL::VERSION>. (See L<version> for more on "lax" |
2370 |
|
|
version criteria.) |
2371 |
|
|
|
2372 |
|
|
C<base> no longer internally skips loading modules it has already loaded |
2373 |
|
|
and instead relies on C<require> to inspect C<%INC>. This fixes a bug |
2374 |
|
|
when C<base> is used with code that clear C<%INC> to force a module to |
2375 |
|
|
be reloaded. |
2376 |
|
|
|
2377 |
|
|
=item * |
2378 |
|
|
|
2379 |
|
|
L<Carp> has been upgraded from version 1.20 to 1.26. |
2380 |
|
|
|
2381 |
|
|
It now includes last read filehandle info and puts a dot after the file |
2382 |
|
|
and line number, just like errors from C<die> [perl #106538]. |
2383 |
|
|
|
2384 |
|
|
=item * |
2385 |
|
|
|
2386 |
|
|
L<charnames> has been updated from version 1.18 to 1.30. |
2387 |
|
|
|
2388 |
|
|
L<charnames> can now be invoked with a new option, C<:loose>, |
2389 |
|
|
which is like the existing C<:full> option, but enables Unicode loose |
2390 |
|
|
name matching. Details are in L<charnames/LOOSE MATCHES>. |
2391 |
|
|
|
2392 |
|
|
=item * |
2393 |
|
|
|
2394 |
|
|
L<B::Deparse> has been upgraded from version 1.03 to 1.14. This fixes |
2395 |
|
|
numerous deparsing bugs. |
2396 |
|
|
|
2397 |
|
|
=item * |
2398 |
|
|
|
2399 |
|
|
L<CGI> has been upgraded from version 3.52 to 3.59. |
2400 |
|
|
|
2401 |
|
|
It uses the public and documented FCGI.pm API in CGI::Fast. CGI::Fast was |
2402 |
|
|
using an FCGI API that was deprecated and removed from documentation |
2403 |
|
|
more than ten years ago. Usage of this deprecated API with FCGI E<gt>= |
2404 |
|
|
0.70 or FCGI E<lt>= 0.73 introduces a security issue. |
2405 |
|
|
L<https://rt.cpan.org/Public/Bug/Display.html?id=68380> |
2406 |
|
|
L<http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-2766> |
2407 |
|
|
|
2408 |
|
|
Things that may break your code: |
2409 |
|
|
|
2410 |
|
|
C<url()> was fixed to return C<PATH_INFO> when it is explicitly requested |
2411 |
|
|
with either the C<path=E<gt>1> or C<path_info=E<gt>1> flag. |
2412 |
|
|
|
2413 |
|
|
If your code is running under mod_rewrite (or compatible) and you are |
2414 |
|
|
calling C<self_url()> or you are calling C<url()> and passing |
2415 |
|
|
C<path_info=E<gt>1>, these methods will actually be returning |
2416 |
|
|
C<PATH_INFO> now, as you have explicitly requested or C<self_url()> |
2417 |
|
|
has requested on your behalf. |
2418 |
|
|
|
2419 |
|
|
The C<PATH_INFO> has been omitted in such URLs since the issue was |
2420 |
|
|
introduced in the 3.12 release in December, 2005. |
2421 |
|
|
|
2422 |
|
|
This bug is so old your application may have come to depend on it or |
2423 |
|
|
workaround it. Check for application before upgrading to this release. |
2424 |
|
|
|
2425 |
|
|
Examples of affected method calls: |
2426 |
|
|
|
2427 |
|
|
$q->url(-absolute => 1, -query => 1, -path_info => 1); |
2428 |
|
|
$q->url(-path=>1); |
2429 |
|
|
$q->url(-full=>1,-path=>1); |
2430 |
|
|
$q->url(-rewrite=>1,-path=>1); |
2431 |
|
|
$q->self_url(); |
2432 |
|
|
|
2433 |
|
|
We no longer read from STDIN when the Content-Length is not set, |
2434 |
|
|
preventing requests with no Content-Length from freezing in some cases. |
2435 |
|
|
This is consistent with the CGI RFC 3875, and is also consistent with |
2436 |
|
|
CGI::Simple. However, the old behavior may have been expected by some |
2437 |
|
|
command-line uses of CGI.pm. |
2438 |
|
|
|
2439 |
|
|
In addition, the DELETE HTTP verb is now supported. |
2440 |
|
|
|
2441 |
|
|
=item * |
2442 |
|
|
|
2443 |
|
|
L<Compress::Zlib> has been upgraded from version 2.035 to 2.048. |
2444 |
|
|
|
2445 |
|
|
IO::Compress::Zip and IO::Uncompress::Unzip now have support for LZMA |
2446 |
|
|
(method 14). There is a fix for a CRC issue in IO::Compress::Unzip and |
2447 |
|
|
it supports Streamed Stored context now. And fixed a Zip64 issue in |
2448 |
|
|
IO::Compress::Zip when the content size was exactly 0xFFFFFFFF. |
2449 |
|
|
|
2450 |
|
|
=item * |
2451 |
|
|
|
2452 |
|
|
L<Digest::SHA> has been upgraded from version 5.61 to 5.71. |
2453 |
|
|
|
2454 |
|
|
Added BITS mode to the addfile method and shasum. This makes |
2455 |
|
|
partial-byte inputs possible via files/STDIN and allows shasum to check |
2456 |
|
|
all 8074 NIST Msg vectors, where previously special programming was |
2457 |
|
|
required to do this. |
2458 |
|
|
|
2459 |
|
|
=item * |
2460 |
|
|
|
2461 |
|
|
L<Encode> has been upgraded from version 2.42 to 2.44. |
2462 |
|
|
|
2463 |
|
|
Missing aliases added, a deep recursion error fixed and various |
2464 |
|
|
documentation updates. |
2465 |
|
|
|
2466 |
|
|
Addressed 'decode_xs n-byte heap-overflow' security bug in Unicode.xs |
2467 |
|
|
(CVE-2011-2939). (5.14.2) |
2468 |
|
|
|
2469 |
|
|
=item * |
2470 |
|
|
|
2471 |
|
|
L<ExtUtils::CBuilder> updated from version 0.280203 to 0.280206. |
2472 |
|
|
|
2473 |
|
|
The new version appends CFLAGS and LDFLAGS to their Config.pm |
2474 |
|
|
counterparts. |
2475 |
|
|
|
2476 |
|
|
=item * |
2477 |
|
|
|
2478 |
|
|
L<ExtUtils::ParseXS> has been upgraded from version 2.2210 to 3.16. |
2479 |
|
|
|
2480 |
|
|
Much of L<ExtUtils::ParseXS>, the module behind the XS compiler C<xsubpp>, |
2481 |
|
|
was rewritten and cleaned up. It has been made somewhat more extensible |
2482 |
|
|
and now finally uses strictures. |
2483 |
|
|
|
2484 |
|
|
The typemap logic has been moved into a separate module, |
2485 |
|
|
L<ExtUtils::Typemaps>. See L</New Modules and Pragmata>, above. |
2486 |
|
|
|
2487 |
|
|
For a complete set of changes, please see the ExtUtils::ParseXS |
2488 |
|
|
changelog, available on the CPAN. |
2489 |
|
|
|
2490 |
|
|
=item * |
2491 |
|
|
|
2492 |
|
|
L<File::Glob> has been upgraded from version 1.12 to 1.17. |
2493 |
|
|
|
2494 |
|
|
On Windows, tilde (~) expansion now checks the C<USERPROFILE> environment |
2495 |
|
|
variable, after checking C<HOME>. |
2496 |
|
|
|
2497 |
|
|
It has a new C<:bsd_glob> export tag, intended to replace C<:glob>. Like |
2498 |
|
|
C<:glob> it overrides C<glob> with a function that does not split the glob |
2499 |
|
|
pattern into words, but, unlike C<:glob>, it iterates properly in scalar |
2500 |
|
|
context, instead of returning the last file. |
2501 |
|
|
|
2502 |
|
|
There are other changes affecting Perl's own C<glob> operator (which uses |
2503 |
|
|
File::Glob internally, except on VMS). See L</Performance Enhancements> |
2504 |
|
|
and L</Selected Bug Fixes>. |
2505 |
|
|
|
2506 |
|
|
=item * |
2507 |
|
|
|
2508 |
|
|
L<FindBin> updated from version 1.50 to 1.51. |
2509 |
|
|
|
2510 |
|
|
It no longer returns a wrong result if a script of the same name as the |
2511 |
|
|
current one exists in the path and is executable. |
2512 |
|
|
|
2513 |
|
|
=item * |
2514 |
|
|
|
2515 |
|
|
L<HTTP::Tiny> has been upgraded from version 0.012 to 0.017. |
2516 |
|
|
|
2517 |
|
|
Added support for using C<$ENV{http_proxy}> to set the default proxy host. |
2518 |
|
|
|
2519 |
|
|
Adds additional shorthand methods for all common HTTP verbs, |
2520 |
|
|
a C<post_form()> method for POST-ing x-www-form-urlencoded data and |
2521 |
|
|
a C<www_form_urlencode()> utility method. |
2522 |
|
|
|
2523 |
|
|
=item * |
2524 |
|
|
|
2525 |
|
|
L<IO> has been upgraded from version 1.25_04 to 1.25_06, and L<IO::Handle> |
2526 |
|
|
from version 1.31 to 1.33. |
2527 |
|
|
|
2528 |
|
|
Together, these upgrades fix a problem with IO::Handle's C<getline> and |
2529 |
|
|
C<getlines> methods. When these methods are called on the special ARGV |
2530 |
|
|
handle, the next file is automatically opened, as happens with the built-in |
2531 |
|
|
C<E<lt>E<gt>> and C<readline> functions. But, unlike the built-ins, these |
2532 |
|
|
methods were not respecting the caller's use of the L<open> pragma and |
2533 |
|
|
applying the approprate I/O layers to the newly-opened file |
2534 |
|
|
[rt.cpan.org #66474]. |
2535 |
|
|
|
2536 |
|
|
=item * |
2537 |
|
|
|
2538 |
|
|
L<IPC::Cmd> has been upgraded from version 0.70 to 0.76. |
2539 |
|
|
|
2540 |
|
|
Capturing of command output (both C<STDOUT> and C<STDERR>) is now supported |
2541 |
|
|
using L<IPC::Open3> on MSWin32 without requiring L<IPC::Run>. |
2542 |
|
|
|
2543 |
|
|
=item * |
2544 |
|
|
|
2545 |
|
|
L<IPC::Open3> has been upgraded from version 1.09 to 1.12. |
2546 |
|
|
|
2547 |
argrath |
1.1 |
=over 4 |
2548 |
|
|
|
2549 |
|
|
=item * |
2550 |
|
|
|
2551 |
argrath |
1.16 |
Fixes a bug which prevented use of C<open3> on Windows when C<*STDIN>, |
2552 |
|
|
C<*STDOUT> or C<*STDERR> had been localized. |
2553 |
|
|
|
2554 |
|
|
=item * |
2555 |
|
|
|
2556 |
|
|
Fixes a bug which prevented duplicating numeric file descriptors on Windows. |
2557 |
|
|
|
2558 |
|
|
=item * |
2559 |
|
|
|
2560 |
|
|
C<open3> with "-" for the program name works once more. This was broken in |
2561 |
|
|
version 1.06 (and hence in Perl 5.14.0) [perl #95748]. |
2562 |
|
|
|
2563 |
|
|
=back |
2564 |
|
|
|
2565 |
|
|
=item * |
2566 |
|
|
|
2567 |
|
|
L<Locale::Codes> has been upgraded from version 3.16 to 3.21. |
2568 |
|
|
|
2569 |
|
|
Added Language Extension codes (langext) and Language Variation codes (langvar) |
2570 |
|
|
as defined in the IANA language registry. |
2571 |
|
|
|
2572 |
|
|
Added language codes from ISO 639-5 |
2573 |
|
|
|
2574 |
|
|
Added language/script codes from the IANA language subtag registry |
2575 |
|
|
|
2576 |
|
|
Fixed an uninitialized value warning [rt.cpan.org #67438]. |
2577 |
|
|
|
2578 |
|
|
Fixed the return value for the all_XXX_codes and all_XXX_names functions |
2579 |
|
|
[rt.cpan.org #69100]. |
2580 |
|
|
|
2581 |
|
|
Reorganized modules to move Locale::MODULE to Locale::Codes::MODULE to allow |
2582 |
|
|
for cleaner future additions. The original four modules (Locale::Language, |
2583 |
|
|
Locale::Currency, Locale::Country, Locale::Script) will continue to work, but |
2584 |
|
|
all new sets of codes will be added in the Locale::Codes namespace. |
2585 |
|
|
|
2586 |
|
|
The code2XXX, XXX2code, all_XXX_codes, and all_XXX_names functions now |
2587 |
|
|
support retired codes. All codesets may be specified by a constant or |
2588 |
|
|
by their name now. Previously, they were specified only by a constant. |
2589 |
|
|
|
2590 |
|
|
The alias_code function exists for backward compatibility. It has been |
2591 |
|
|
replaced by rename_country_code. The alias_code function will be |
2592 |
|
|
removed some time after September, 2013. |
2593 |
|
|
|
2594 |
|
|
All work is now done in the central module (Locale::Codes). Previously, |
2595 |
|
|
some was still done in the wrapper modules (Locale::Codes::*). Added |
2596 |
|
|
Language Family codes (langfam) as defined in ISO 639-5. |
2597 |
|
|
|
2598 |
|
|
=item * |
2599 |
|
|
|
2600 |
|
|
L<Math::BigFloat> has been upgraded from version 1.993 to 1.997. |
2601 |
|
|
|
2602 |
|
|
The C<numify> method has been corrected to return a normalised Perl number |
2603 |
|
|
(the result of C<0 + $thing>), instead of a string [rt.cpan.org #66732]. |
2604 |
|
|
|
2605 |
|
|
=item * |
2606 |
|
|
|
2607 |
|
|
L<Math::BigInt> has been upgraded from version 1.994 to 1.998. |
2608 |
|
|
|
2609 |
|
|
It provides a new C<bsgn> method that complements the C<babs> method. |
2610 |
|
|
|
2611 |
|
|
It fixes the internal C<objectify> function's handling of "foreign objects" |
2612 |
|
|
so they are converted to the appropriate class (Math::BigInt or |
2613 |
|
|
Math::BigFloat). |
2614 |
|
|
|
2615 |
|
|
=item * |
2616 |
|
|
|
2617 |
|
|
L<Math::BigRat> has been upgraded from version 0.2602 to 0.2603. |
2618 |
|
|
|
2619 |
|
|
C<int()> on a Math::BigRat object containing -1/2 now creates a |
2620 |
|
|
Math::BigInt containing 0, rather than -0. L<Math::BigInt> does not even |
2621 |
|
|
support negative zero, so the resulting object was actually malformed |
2622 |
|
|
[perl #95530]. |
2623 |
|
|
|
2624 |
|
|
=item * |
2625 |
|
|
|
2626 |
|
|
L<Math::Complex> has been upgraded from version 1.56 to 1.59 |
2627 |
|
|
and L<Math::Trig> from version 1.2 to 1.22. |
2628 |
|
|
|
2629 |
|
|
Fixes include: correct copy constructor usage; fix polarwise formatting with |
2630 |
|
|
numeric format specifier; and more stable C<great_circle_direction> algorithm. |
2631 |
|
|
|
2632 |
|
|
=item * |
2633 |
|
|
|
2634 |
|
|
L<Module::CoreList> has been upgraded from version 2.51 to 2.66. |
2635 |
|
|
|
2636 |
|
|
The C<corelist> utility now understands the C<-r> option for displaying |
2637 |
|
|
Perl release dates and the C<--diff> option to print the set of modlib |
2638 |
|
|
changes between two perl distributions. |
2639 |
|
|
|
2640 |
|
|
=item * |
2641 |
|
|
|
2642 |
|
|
L<Module::Metadata> has been upgraded from version 1.000004 to 1.000009. |
2643 |
|
|
|
2644 |
|
|
Adds C<provides> method to generate a CPAN META provides data structure |
2645 |
|
|
correctly; use of C<package_versions_from_directory> is discouraged. |
2646 |
|
|
|
2647 |
|
|
=item * |
2648 |
|
|
|
2649 |
|
|
L<ODBM_File> has been upgraded from version 1.10 to 1.12. |
2650 |
|
|
|
2651 |
|
|
The XS code is now compiled with C<PERL_NO_GET_CONTEXT>, which will aid |
2652 |
|
|
performance under ithreads. |
2653 |
|
|
|
2654 |
|
|
=item * |
2655 |
|
|
|
2656 |
|
|
L<open> has been upgraded from version 1.08 to 1.10. |
2657 |
|
|
|
2658 |
|
|
It no longer turns off layers on standard handles when invoked without the |
2659 |
|
|
":std" directive. Similarly, when invoked I<with> the ":std" directive, it |
2660 |
|
|
now clears layers on STDERR before applying the new ones, and not just on |
2661 |
|
|
STDIN and STDOUT [perl #92728]. |
2662 |
|
|
|
2663 |
|
|
=item * |
2664 |
|
|
|
2665 |
|
|
L<overload> has been upgraded from version 1.13 to 1.18. |
2666 |
|
|
|
2667 |
|
|
C<overload::Overloaded> no longer calls C<can> on the class, but uses |
2668 |
|
|
another means to determine whether the object has overloading. It was |
2669 |
|
|
never correct for it to call C<can>, as overloading does not respect |
2670 |
|
|
AUTOLOAD. So classes that autoload methods and implement C<can> no longer |
2671 |
|
|
have to account for overloading [perl #40333]. |
2672 |
|
|
|
2673 |
|
|
A warning is now produced for invalid arguments. See L</New Diagnostics>. |
2674 |
|
|
|
2675 |
|
|
=item * |
2676 |
|
|
|
2677 |
|
|
L<PerlIO::scalar> has been upgraded from version 0.11 to 0.14. |
2678 |
|
|
|
2679 |
|
|
(This is the module that implements C<< open $fh, '>', \$scalar >>.) |
2680 |
|
|
|
2681 |
|
|
It fixes a problem with C<< open my $fh, ">", \$scalar >> not working if |
2682 |
|
|
C<$scalar> is a copy-on-write scalar. (5.14.2) |
2683 |
|
|
|
2684 |
|
|
It also fixes a hang that occurs with C<readline> or C<< <$fh> >> if a |
2685 |
|
|
typeglob has been assigned to $scalar [perl #92258]. |
2686 |
|
|
|
2687 |
|
|
It no longer assumes during C<seek> that $scalar is a string internally. |
2688 |
|
|
If it didn't crash, it was close to doing so [perl #92706]. Also, the |
2689 |
|
|
internal print routine no longer assumes that the position set by C<seek> |
2690 |
|
|
is valid, but extends the string to that position, filling the intervening |
2691 |
|
|
bytes (between the old length and the seek position) with nulls |
2692 |
|
|
[perl #78980]. |
2693 |
|
|
|
2694 |
|
|
Printing to an in-memory handle now works if the $scalar holds a reference, |
2695 |
|
|
stringifying the reference before modifying it. References used to be |
2696 |
|
|
treated as empty strings. |
2697 |
|
|
|
2698 |
|
|
Printing to an in-memory handle no longer crashes if the $scalar happens to |
2699 |
|
|
hold a number internally, but no string buffer. |
2700 |
|
|
|
2701 |
|
|
Printing to an in-memory handle no longer creates scalars that confuse |
2702 |
|
|
the regular expression engine [perl #108398]. |
2703 |
|
|
|
2704 |
|
|
=item * |
2705 |
|
|
|
2706 |
|
|
L<Pod::Functions> has been upgraded from version 1.04 to 1.05. |
2707 |
|
|
|
2708 |
|
|
F<Functions.pm> is now generated at perl build time from annotations in |
2709 |
|
|
F<perlfunc.pod>. This will ensure that L<Pod::Functions> and L<perlfunc> |
2710 |
|
|
remain in synchronisation. |
2711 |
|
|
|
2712 |
|
|
=item * |
2713 |
|
|
|
2714 |
|
|
L<Pod::Html> has been upgraded from version 1.11 to 1.1502. |
2715 |
|
|
|
2716 |
|
|
This is an extensive rewrite of Pod::Html to use L<Pod::Simple> under |
2717 |
|
|
the hood. The output has changed significantly. |
2718 |
|
|
|
2719 |
|
|
=item * |
2720 |
|
|
|
2721 |
|
|
L<Pod::Perldoc> has been upgraded from version 3.15_03 to 3.17. |
2722 |
|
|
|
2723 |
|
|
It corrects the search paths on VMS [perl #90640]. (5.14.1) |
2724 |
|
|
|
2725 |
|
|
The B<-v> option now fetches the right section for C<$0>. |
2726 |
|
|
|
2727 |
|
|
This upgrade has numerous significant fixes. Consult its changelog on |
2728 |
|
|
the CPAN for more information. |
2729 |
|
|
|
2730 |
|
|
=item * |
2731 |
|
|
|
2732 |
|
|
L<POSIX> has been upgraded from version 1.24 to 1.30. |
2733 |
|
|
|
2734 |
|
|
L<POSIX> no longer uses L<AutoLoader>. Any code which was relying on this |
2735 |
|
|
implementation detail was buggy, and may fail as a result of this change. |
2736 |
|
|
The module's Perl code has been considerably simplified, roughly halving |
2737 |
|
|
the number of lines, with no change in functionality. The XS code has |
2738 |
|
|
been refactored to reduce the size of the shared object by about 12%, |
2739 |
|
|
with no change in functionality. More POSIX functions now have tests. |
2740 |
|
|
|
2741 |
|
|
C<sigsuspend> and C<pause> now run signal handlers before returning, as the |
2742 |
|
|
whole point of these two functions is to wait until a signal has |
2743 |
|
|
arrived, and then return I<after> it has been triggered. Delayed, or |
2744 |
|
|
"safe", signals were preventing that from happening, possibly resulting in |
2745 |
|
|
race conditions [perl #107216]. |
2746 |
|
|
|
2747 |
|
|
C<POSIX::sleep> is now a direct call into the underlying OS C<sleep> |
2748 |
|
|
function, instead of being a Perl wrapper on C<CORE::sleep>. |
2749 |
|
|
C<POSIX::dup2> now returns the correct value on Win32 (I<i.e.>, the file |
2750 |
|
|
descriptor). C<POSIX::SigSet> C<sigsuspend> and C<sigpending> and |
2751 |
|
|
C<POSIX::pause> now dispatch safe signals immediately before returning to |
2752 |
|
|
their caller. |
2753 |
|
|
|
2754 |
|
|
C<POSIX::Termios::setattr> now defaults the third argument to C<TCSANOW>, |
2755 |
|
|
instead of 0. On most platforms C<TCSANOW> is defined as 0, but on some |
2756 |
|
|
0 is not a valid parameter, which caused a call with defaults to fail. |
2757 |
|
|
|
2758 |
|
|
=item * |
2759 |
|
|
|
2760 |
|
|
L<Socket> has been upgraded from version 1.94 to 2.000. |
2761 |
|
|
|
2762 |
|
|
It has new functions and constants for handling IPv6 sockets: |
2763 |
|
|
|
2764 |
|
|
pack_ipv6_mreq |
2765 |
|
|
unpack_ipv6_mreq |
2766 |
|
|
IPV6_ADD_MEMBERSHIP |
2767 |
|
|
IPV6_DROP_MEMBERSHIP |
2768 |
|
|
IPV6_MTU |
2769 |
|
|
IPV6_MTU_DISCOVER |
2770 |
|
|
IPV6_MULTICAST_HOPS |
2771 |
|
|
IPV6_MULTICAST_IF |
2772 |
|
|
IPV6_MULTICAST_LOOP |
2773 |
|
|
IPV6_UNICAST_HOPS |
2774 |
|
|
IPV6_V6ONLY |
2775 |
|
|
|
2776 |
|
|
=item * |
2777 |
|
|
|
2778 |
|
|
L<Storable> has been upgraded from version 2.27 to 2.34. |
2779 |
|
|
|
2780 |
|
|
It no longer turns copy-on-write scalars into read-only scalars when |
2781 |
|
|
freezing and thawing. |
2782 |
|
|
|
2783 |
|
|
=item * |
2784 |
|
|
|
2785 |
|
|
L<Sys::Syslog> has been upgraded from version 0.27 to 0.29. |
2786 |
|
|
|
2787 |
|
|
This upgrade closes many outstanding bugs. |
2788 |
|
|
|
2789 |
|
|
=item * |
2790 |
|
|
|
2791 |
|
|
L<Term::ANSIColor> has been upgraded from version 3.00 to 3.01. |
2792 |
|
|
|
2793 |
|
|
Only interpret an initial array reference as a list of colors, not any initial |
2794 |
|
|
reference, allowing the colored function to work properly on objects with |
2795 |
|
|
stringification defined. |
2796 |
|
|
|
2797 |
|
|
=item * |
2798 |
|
|
|
2799 |
|
|
L<Term::ReadLine> has been upgraded from version 1.07 to 1.09. |
2800 |
|
|
|
2801 |
|
|
Term::ReadLine now supports any event loop, including unpublished ones and |
2802 |
|
|
simple L<IO::Select>, loops without the need to rewrite existing code for |
2803 |
|
|
any particular framework [perl #108470]. |
2804 |
|
|
|
2805 |
|
|
=item * |
2806 |
|
|
|
2807 |
|
|
L<threads::shared> has been upgraded from version 1.37 to 1.40. |
2808 |
|
|
|
2809 |
|
|
Destructors on shared objects used to be ignored sometimes if the objects |
2810 |
|
|
were referenced only by shared data structures. This has been mostly |
2811 |
|
|
fixed, but destructors may still be ignored if the objects still exist at |
2812 |
|
|
global destruction time [perl #98204]. |
2813 |
|
|
|
2814 |
|
|
=item * |
2815 |
|
|
|
2816 |
|
|
L<Unicode::Collate> has been upgraded from version 0.73 to 0.89. |
2817 |
|
|
|
2818 |
|
|
Updated to CLDR 1.9.1 |
2819 |
|
|
|
2820 |
|
|
Locales updated to CLDR 2.0: mk, mt, nb, nn, ro, ru, sk, sr, sv, uk, |
2821 |
|
|
zh__pinyin, zh__stroke |
2822 |
|
|
|
2823 |
|
|
Newly supported locales: bn, fa, ml, mr, or, pa, sa, si, si__dictionary, |
2824 |
|
|
sr_Latn, sv__reformed, ta, te, th, ur, wae. |
2825 |
|
|
|
2826 |
|
|
Tailored compatibility ideographs as well as unified ideographs for the |
2827 |
|
|
locales: ja, ko, zh__big5han, zh__gb2312han, zh__pinyin, zh__stroke. |
2828 |
|
|
|
2829 |
|
|
Locale/*.pl files are now searched for in @INC. |
2830 |
|
|
|
2831 |
|
|
=item * |
2832 |
|
|
|
2833 |
|
|
L<Unicode::Normalize> has been upgraded from version 1.10 to 1.14. |
2834 |
|
|
|
2835 |
|
|
Fixes for the removal of F<unicore/CompositionExclusions.txt> from core. |
2836 |
|
|
|
2837 |
|
|
=item * |
2838 |
|
|
|
2839 |
|
|
L<Unicode::UCD> has been upgraded from version 0.32 to 0.43. |
2840 |
|
|
|
2841 |
|
|
This adds four new functions: C<prop_aliases()> and |
2842 |
|
|
C<prop_value_aliases()>, which are used to find all the Unicode-approved |
2843 |
|
|
synonyms for property names, or to convert from one name to another; |
2844 |
|
|
C<prop_invlist> which returns all the code points matching a given |
2845 |
|
|
Unicode binary property; and C<prop_invmap> which returns the complete |
2846 |
|
|
specification of a given Unicode property. |
2847 |
|
|
|
2848 |
|
|
=item * |
2849 |
|
|
|
2850 |
|
|
L<Win32API::File> has been upgraded from version 0.1101 to 0.1200. |
2851 |
|
|
|
2852 |
|
|
Added SetStdHandle and GetStdHandle functions |
2853 |
argrath |
1.1 |
|
2854 |
|
|
=back |
2855 |
|
|
|
2856 |
|
|
=head2 Removed Modules and Pragmata |
2857 |
|
|
|
2858 |
argrath |
1.7 |
(削除されたモジュールとプラグマ) |
2859 |
|
|
|
2860 |
argrath |
1.6 |
=begin original |
2861 |
|
|
|
2862 |
argrath |
1.1 |
As promised in Perl 5.14.0's release notes, the following modules have |
2863 |
|
|
been removed from the core distribution, and if needed should be installed |
2864 |
|
|
from CPAN instead. |
2865 |
|
|
|
2866 |
argrath |
1.6 |
=end original |
2867 |
|
|
|
2868 |
|
|
Perl 5.14.0 のリリースノートで約束した通り、以下のモジュールがコア配布から |
2869 |
|
|
削除されました; もし必要なら代わりに CPAN からインストールしてください。 |
2870 |
|
|
|
2871 |
argrath |
1.1 |
=over |
2872 |
|
|
|
2873 |
|
|
=item * |
2874 |
|
|
|
2875 |
argrath |
1.6 |
=begin original |
2876 |
|
|
|
2877 |
argrath |
1.1 |
C<Devel::DProf> has been removed from the Perl core. Prior version was |
2878 |
|
|
20110228.00. |
2879 |
|
|
|
2880 |
argrath |
1.6 |
=end original |
2881 |
|
|
|
2882 |
|
|
C<Devel::DProf> は Perl コアから削除されました。 |
2883 |
|
|
以前のバージョンは 20110228.00 でした。 |
2884 |
|
|
|
2885 |
argrath |
1.1 |
=item * |
2886 |
|
|
|
2887 |
argrath |
1.6 |
=begin original |
2888 |
|
|
|
2889 |
argrath |
1.1 |
C<Shell> has been removed from the Perl core. Prior version was 0.72_01. |
2890 |
|
|
|
2891 |
argrath |
1.6 |
=end original |
2892 |
|
|
|
2893 |
|
|
C<Shell> は Perl コアから削除されました。 |
2894 |
|
|
以前のバージョンは 0.72_01 でした。 |
2895 |
|
|
|
2896 |
argrath |
1.1 |
=back |
2897 |
|
|
|
2898 |
|
|
=head1 Documentation |
2899 |
|
|
|
2900 |
argrath |
1.8 |
(文書) |
2901 |
|
|
|
2902 |
argrath |
1.1 |
=head2 New Documentation |
2903 |
|
|
|
2904 |
argrath |
1.8 |
(新しい文書) |
2905 |
|
|
|
2906 |
argrath |
1.1 |
=head3 L<perldtrace> |
2907 |
|
|
|
2908 |
argrath |
1.8 |
=begin original |
2909 |
|
|
|
2910 |
argrath |
1.1 |
L<perldtrace> describes Perl's DTrace support, listing the provided probes |
2911 |
|
|
and gives examples of their use. |
2912 |
|
|
|
2913 |
argrath |
1.8 |
=end original |
2914 |
|
|
|
2915 |
|
|
L<perldtrace> は Perl の DTrace 対応について記述し、提供している |
2916 |
|
|
プローブの一覧と使用例を提供します。 |
2917 |
|
|
|
2918 |
argrath |
1.1 |
=head3 L<perlexperiment> |
2919 |
|
|
|
2920 |
argrath |
1.8 |
=begin original |
2921 |
|
|
|
2922 |
argrath |
1.1 |
This document is intended to provide a list of experimental features in |
2923 |
|
|
Perl. It is still a work in progress. |
2924 |
|
|
|
2925 |
argrath |
1.8 |
=end original |
2926 |
|
|
|
2927 |
|
|
この文書は Perl の実験的機能の一覧を提供することを意図しています。 |
2928 |
|
|
これはまだ作業中です。 |
2929 |
|
|
|
2930 |
argrath |
1.1 |
=head3 L<perlootut> |
2931 |
|
|
|
2932 |
argrath |
1.8 |
=begin original |
2933 |
|
|
|
2934 |
argrath |
1.1 |
This a new OO tutorial. It focuses on basic OO concepts, and then recommends |
2935 |
|
|
that readers choose an OO framework from CPAN. |
2936 |
|
|
|
2937 |
argrath |
1.8 |
=end original |
2938 |
|
|
|
2939 |
|
|
これは新しい OO チュートリアルです。 |
2940 |
|
|
基本的な OO コンセプトに焦点を合わせ、読者が CPAN から OO フレームワークを |
2941 |
|
|
選ぶことを推奨しています。 |
2942 |
|
|
|
2943 |
argrath |
1.1 |
=head3 L<perlxstypemap> |
2944 |
|
|
|
2945 |
argrath |
1.8 |
=begin original |
2946 |
|
|
|
2947 |
argrath |
1.1 |
The new manual describes the XS typemapping mechanism in unprecedented |
2948 |
|
|
detail and combines new documentation with information extracted from |
2949 |
|
|
L<perlxs> and the previously unofficial list of all core typemaps. |
2950 |
|
|
|
2951 |
argrath |
1.8 |
=end original |
2952 |
|
|
|
2953 |
|
|
この新しいマニュアルは、前例のないほど詳細に XS typemap 機構について記述し、 |
2954 |
|
|
新しい文書を L<perlxs> から抽出された情報および以前は非公式だった |
2955 |
|
|
全てのコア typemap の一覧と結合します。 |
2956 |
|
|
|
2957 |
argrath |
1.1 |
=head2 Changes to Existing Documentation |
2958 |
|
|
|
2959 |
argrath |
1.8 |
(既存の文書の変更) |
2960 |
|
|
|
2961 |
argrath |
1.1 |
=head3 L<perlapi> |
2962 |
|
|
|
2963 |
|
|
=over 4 |
2964 |
|
|
|
2965 |
|
|
=item * |
2966 |
|
|
|
2967 |
argrath |
1.8 |
=begin original |
2968 |
|
|
|
2969 |
argrath |
1.1 |
The HV API has long accepted negative lengths to indicate that the key is |
2970 |
|
|
in UTF8. Now this is documented. |
2971 |
|
|
|
2972 |
argrath |
1.8 |
=end original |
2973 |
|
|
|
2974 |
|
|
HV API は長い間、キーが UTF8 であることを示すための負数の長さを |
2975 |
|
|
受け付けていました。 |
2976 |
|
|
これが文書化されました。 |
2977 |
|
|
|
2978 |
argrath |
1.1 |
=item * |
2979 |
|
|
|
2980 |
argrath |
1.8 |
=begin original |
2981 |
|
|
|
2982 |
argrath |
1.1 |
The C<boolSV()> macro is now documented. |
2983 |
|
|
|
2984 |
argrath |
1.8 |
=end original |
2985 |
|
|
|
2986 |
|
|
C<boolSV()> が文書化されました。 |
2987 |
|
|
|
2988 |
argrath |
1.1 |
=back |
2989 |
|
|
|
2990 |
|
|
=head3 L<perlfunc> |
2991 |
|
|
|
2992 |
|
|
=over 4 |
2993 |
|
|
|
2994 |
|
|
=item * |
2995 |
|
|
|
2996 |
argrath |
1.8 |
=begin original |
2997 |
|
|
|
2998 |
argrath |
1.1 |
C<dbmopen> treats a 0 mode as a special case, that prevents a nonexistent |
2999 |
|
|
file from being created. This has been the case since Perl 5.000, but was |
3000 |
|
|
never documented anywhere. Now the perlfunc entry mentions it |
3001 |
|
|
[perl #90064]. |
3002 |
|
|
|
3003 |
argrath |
1.8 |
=end original |
3004 |
|
|
|
3005 |
|
|
C<dbmopen> はモード 0 を特殊な場合として扱い、この場合存在しないファイルを |
3006 |
|
|
作成しません。 |
3007 |
|
|
これは Perl 5.000 からありましたが、どこにも文書化されていませんでした。 |
3008 |
|
|
perlfunc のエントリでこれに触れるようになりました [perl #90064]。 |
3009 |
|
|
|
3010 |
argrath |
1.1 |
=item * |
3011 |
|
|
|
3012 |
argrath |
1.8 |
=begin original |
3013 |
|
|
|
3014 |
argrath |
1.16 |
As an accident of history, C<open $fh, '<:', ...> applies the default |
3015 |
argrath |
1.1 |
layers for the platform (C<:raw> on Unix, C<:crlf> on Windows), ignoring |
3016 |
|
|
whatever is declared by L<open.pm|open>. This seems such a useful feature |
3017 |
|
|
it has been documented in L<perlfunc|perlfunc/open> and L<open>. |
3018 |
|
|
|
3019 |
argrath |
1.8 |
=end original |
3020 |
|
|
|
3021 |
argrath |
1.16 |
歴史上の偶然により、C<open $fh, '<:', ...> はプラットフォームのデフォルト層 |
3022 |
argrath |
1.8 |
(Unix では C<:raw>、Windows では C<:crlf>)を適用し、L<open.pm|open> で |
3023 |
|
|
宣言されていたものを無視していました。 |
3024 |
|
|
これは有効な機能に思えるので、L<perlfunc|perlfunc/open> と L<open> に |
3025 |
|
|
文書化されました。 |
3026 |
|
|
|
3027 |
argrath |
1.1 |
=item * |
3028 |
|
|
|
3029 |
argrath |
1.8 |
=begin original |
3030 |
|
|
|
3031 |
argrath |
1.1 |
The entry for C<split> has been rewritten. It is now far clearer than |
3032 |
|
|
before. |
3033 |
|
|
|
3034 |
argrath |
1.8 |
=end original |
3035 |
|
|
|
3036 |
|
|
C<split> のエントリが書き直されました。 |
3037 |
|
|
以前より遥かに明確になりました。 |
3038 |
|
|
|
3039 |
argrath |
1.1 |
=back |
3040 |
|
|
|
3041 |
|
|
=head3 L<perlguts> |
3042 |
|
|
|
3043 |
|
|
=over 4 |
3044 |
|
|
|
3045 |
|
|
=item * |
3046 |
|
|
|
3047 |
argrath |
1.8 |
=begin original |
3048 |
|
|
|
3049 |
argrath |
1.1 |
A new section, L<Autoloading with XSUBs|perlguts/Autoloading with XSUBs>, |
3050 |
|
|
has been added, which explains the two APIs for accessing the name of the |
3051 |
|
|
autoloaded sub. |
3052 |
|
|
|
3053 |
argrath |
1.8 |
=end original |
3054 |
|
|
|
3055 |
|
|
オートロードされたサブルーチンの名前にアクセスするための二つの API に |
3056 |
|
|
ついて説明した |
3057 |
|
|
L<Autoloading with XSUBs|perlguts/Autoloading with XSUBs> という新しい |
3058 |
|
|
章が追加されました。 |
3059 |
|
|
|
3060 |
argrath |
1.1 |
=item * |
3061 |
|
|
|
3062 |
argrath |
1.8 |
=begin original |
3063 |
|
|
|
3064 |
argrath |
1.1 |
Some of the function descriptions in L<perlguts> were confusing, as it was |
3065 |
|
|
not clear whether they referred to the function above or below the |
3066 |
|
|
description. This has been clarified [perl #91790]. |
3067 |
|
|
|
3068 |
argrath |
1.8 |
=end original |
3069 |
|
|
|
3070 |
|
|
L<perlguts> のいくつかの関数の説明は混乱していて、説明の上に書いてある |
3071 |
|
|
関数のことか下に書いてある関数のことかがはっきりしていませんでした。 |
3072 |
|
|
これは明確化されました [perl #91790]。 |
3073 |
|
|
|
3074 |
argrath |
1.1 |
=back |
3075 |
|
|
|
3076 |
|
|
=head3 L<perlobj> |
3077 |
|
|
|
3078 |
|
|
=over 4 |
3079 |
|
|
|
3080 |
|
|
=item * |
3081 |
|
|
|
3082 |
argrath |
1.8 |
=begin original |
3083 |
|
|
|
3084 |
argrath |
1.1 |
This document has been rewritten from scratch, and its coverage of various OO |
3085 |
|
|
concepts has been expanded. |
3086 |
|
|
|
3087 |
argrath |
1.8 |
=end original |
3088 |
|
|
|
3089 |
|
|
この文書は最初から書き直され、様々な OO コンセプトの範囲が拡張されました。 |
3090 |
|
|
|
3091 |
argrath |
1.1 |
=back |
3092 |
|
|
|
3093 |
|
|
=head3 L<perlop> |
3094 |
|
|
|
3095 |
|
|
=over 4 |
3096 |
|
|
|
3097 |
|
|
=item * |
3098 |
|
|
|
3099 |
argrath |
1.8 |
=begin original |
3100 |
|
|
|
3101 |
argrath |
1.1 |
Documentation of the smartmatch operator has been reworked and moved from |
3102 |
|
|
perlsyn to perlop where it belongs. |
3103 |
|
|
|
3104 |
argrath |
1.8 |
=end original |
3105 |
|
|
|
3106 |
|
|
スマートマッチング演算子の文書が書き直され、perlsyn から属する場所である |
3107 |
|
|
perlopに移動しました。 |
3108 |
|
|
|
3109 |
|
|
=begin original |
3110 |
|
|
|
3111 |
argrath |
1.1 |
It has also been corrected for the case of C<undef> on the left-hand |
3112 |
|
|
side. The list of different smart match behaviours had an item in the |
3113 |
|
|
wrong place. |
3114 |
|
|
|
3115 |
argrath |
1.8 |
=end original |
3116 |
|
|
|
3117 |
|
|
左側の C<undef> の場合も修正されました。 |
3118 |
|
|
スマートマッチングの振る舞いの違いの一覧は間違った位置のアイテムに |
3119 |
|
|
ありました。 |
3120 |
|
|
|
3121 |
argrath |
1.1 |
=item * |
3122 |
|
|
|
3123 |
argrath |
1.8 |
=begin original |
3124 |
|
|
|
3125 |
argrath |
1.1 |
Documentation of the ellipsis statement (C<...>) has been reworked and |
3126 |
|
|
moved from perlop to perlsyn. |
3127 |
|
|
|
3128 |
argrath |
1.8 |
=end original |
3129 |
|
|
|
3130 |
|
|
省略文 (C<...>) の文書が書き直され、perlop から perlsyn に移動しました。 |
3131 |
|
|
|
3132 |
argrath |
1.1 |
=item * |
3133 |
|
|
|
3134 |
argrath |
1.8 |
=begin original |
3135 |
|
|
|
3136 |
argrath |
1.1 |
The explanation of bitwise operators has been expanded to explain how they |
3137 |
|
|
work on Unicode strings (5.14.1). |
3138 |
|
|
|
3139 |
argrath |
1.8 |
=end original |
3140 |
|
|
|
3141 |
|
|
ビット単位演算子の説明は、Unicode 文字列に対してどのように動作するかの |
3142 |
|
|
説明が追加されました (5.14.1)。 |
3143 |
|
|
|
3144 |
argrath |
1.1 |
=item * |
3145 |
|
|
|
3146 |
argrath |
1.8 |
=begin original |
3147 |
|
|
|
3148 |
argrath |
1.1 |
More examples for C<m//g> have been added (5.14.1). |
3149 |
|
|
|
3150 |
argrath |
1.8 |
=end original |
3151 |
|
|
|
3152 |
|
|
C<m//g> に関するさらなる例が追加されました (5.14.1)。 |
3153 |
|
|
|
3154 |
argrath |
1.1 |
=item * |
3155 |
|
|
|
3156 |
argrath |
1.8 |
=begin original |
3157 |
|
|
|
3158 |
argrath |
1.1 |
The C<<< <<\FOO >>> here-doc syntax has been documented (5.14.1). |
3159 |
|
|
|
3160 |
argrath |
1.8 |
=end original |
3161 |
|
|
|
3162 |
|
|
C<<< <<\FOO >>> ヒヤドキュメント文法が追加されました (5.14.1)。 |
3163 |
|
|
|
3164 |
argrath |
1.1 |
=back |
3165 |
|
|
|
3166 |
|
|
=head3 L<perlpragma> |
3167 |
|
|
|
3168 |
|
|
=over 4 |
3169 |
|
|
|
3170 |
|
|
=item * |
3171 |
|
|
|
3172 |
argrath |
1.8 |
=begin original |
3173 |
|
|
|
3174 |
argrath |
1.1 |
There is now a standard convention for naming keys in the C<%^H>, |
3175 |
|
|
documented under L<Key naming|perlpragma/Key naming>. |
3176 |
|
|
|
3177 |
argrath |
1.8 |
=end original |
3178 |
|
|
|
3179 |
|
|
C<%^H> のキーの命名に標準規則が定められ、 |
3180 |
|
|
L<Key naming|perlpragma/Key naming> で文書化されました。 |
3181 |
|
|
|
3182 |
argrath |
1.1 |
=back |
3183 |
|
|
|
3184 |
|
|
=head3 L<perlsec/Laundering and Detecting Tainted Data> |
3185 |
|
|
|
3186 |
|
|
=over 4 |
3187 |
|
|
|
3188 |
|
|
=item * |
3189 |
|
|
|
3190 |
argrath |
1.8 |
=begin original |
3191 |
|
|
|
3192 |
argrath |
1.1 |
The example function for checking for taintedness contained a subtle |
3193 |
|
|
error. C<$@> needs to be localized to prevent its changing this |
3194 |
|
|
global's value outside the function. The preferred method to check for |
3195 |
|
|
this remains L<Scalar::Util/tainted>. |
3196 |
|
|
|
3197 |
argrath |
1.8 |
=end original |
3198 |
|
|
|
3199 |
|
|
汚染をチェックする例の関数に僅かなミスがありました。 |
3200 |
|
|
C<$@> は関数の外側でこのグローバルな値を変更されないようにローカル化する |
3201 |
|
|
必要があります。 |
3202 |
|
|
これをチェックするための望ましいメソッドはやはり |
3203 |
|
|
L<Scalar::Util/tainted> です。 |
3204 |
|
|
|
3205 |
argrath |
1.1 |
=back |
3206 |
|
|
|
3207 |
|
|
=head3 L<perllol> |
3208 |
|
|
|
3209 |
|
|
=over |
3210 |
|
|
|
3211 |
|
|
=item * |
3212 |
|
|
|
3213 |
argrath |
1.8 |
=begin original |
3214 |
|
|
|
3215 |
argrath |
1.1 |
L<perllol> has been expanded with examples using the new C<push $scalar> |
3216 |
|
|
syntax introduced in Perl 5.14.0 (5.14.1). |
3217 |
|
|
|
3218 |
argrath |
1.8 |
=end original |
3219 |
|
|
|
3220 |
|
|
L<perllol> は、Perl 5.14.0 で導入された新しい C<push $scalar> 文法を |
3221 |
|
|
使った例が追加されました (5.14.1)。 |
3222 |
|
|
|
3223 |
argrath |
1.1 |
=back |
3224 |
|
|
|
3225 |
|
|
=head3 L<perlmod> |
3226 |
|
|
|
3227 |
|
|
=over |
3228 |
|
|
|
3229 |
|
|
=item * |
3230 |
|
|
|
3231 |
argrath |
1.8 |
=begin original |
3232 |
|
|
|
3233 |
argrath |
1.1 |
L<perlmod> now states explicitly that some types of explicit symbol table |
3234 |
|
|
manipulation are not supported. This codifies what was effectively already |
3235 |
|
|
the case [perl #78074]. |
3236 |
|
|
|
3237 |
argrath |
1.8 |
=end original |
3238 |
|
|
|
3239 |
|
|
L<perlmod> は明示的なシンボルテーブル操作のいくつかの種類は対応していない |
3240 |
|
|
ことを明示的に記すようになりました。 |
3241 |
|
|
これは何が事実上すでに対応していないかを明文化しています [perl #78074]。 |
3242 |
|
|
|
3243 |
argrath |
1.1 |
=back |
3244 |
|
|
|
3245 |
|
|
=head3 L<perlpodstyle> |
3246 |
|
|
|
3247 |
|
|
=over 4 |
3248 |
|
|
|
3249 |
|
|
=item * |
3250 |
|
|
|
3251 |
argrath |
1.8 |
=begin original |
3252 |
|
|
|
3253 |
argrath |
1.1 |
The tips on which formatting codes to use have been corrected and greatly |
3254 |
|
|
expanded. |
3255 |
|
|
|
3256 |
argrath |
1.8 |
=end original |
3257 |
|
|
|
3258 |
|
|
どのフォーマッティングコードを使うかの小技が修正され、大幅に |
3259 |
|
|
拡張されました。 |
3260 |
|
|
|
3261 |
argrath |
1.1 |
=item * |
3262 |
|
|
|
3263 |
argrath |
1.8 |
=begin original |
3264 |
|
|
|
3265 |
argrath |
1.1 |
There are now a couple of example one-liners for previewing POD files after |
3266 |
|
|
they have been edited. |
3267 |
|
|
|
3268 |
argrath |
1.8 |
=end original |
3269 |
|
|
|
3270 |
|
|
POD ファイルを修正した後プレビューするためのいくつかの例となる一行野郎が |
3271 |
|
|
追加されました。 |
3272 |
|
|
|
3273 |
argrath |
1.1 |
=back |
3274 |
|
|
|
3275 |
|
|
=head3 L<perlre> |
3276 |
|
|
|
3277 |
|
|
=over |
3278 |
|
|
|
3279 |
|
|
=item * |
3280 |
|
|
|
3281 |
argrath |
1.8 |
=begin original |
3282 |
|
|
|
3283 |
argrath |
1.1 |
The C<(*COMMIT)> directive is now listed in the right section |
3284 |
|
|
(L<Verbs without an argument|perlre/Verbs without an argument>). |
3285 |
|
|
|
3286 |
argrath |
1.8 |
=end original |
3287 |
|
|
|
3288 |
|
|
C<(*COMMIT)> 指示子は正しい節 |
3289 |
|
|
(L<Verbs without an argument|perlre/Verbs without an argument>) に |
3290 |
|
|
挙げられるようになりました。 |
3291 |
|
|
|
3292 |
argrath |
1.1 |
=back |
3293 |
|
|
|
3294 |
|
|
=head3 L<perlrun> |
3295 |
|
|
|
3296 |
|
|
=over |
3297 |
|
|
|
3298 |
|
|
=item * |
3299 |
|
|
|
3300 |
argrath |
1.8 |
=begin original |
3301 |
|
|
|
3302 |
argrath |
1.1 |
L<perlrun> has undergone a significant clean-up. Most notably, the |
3303 |
|
|
B<-0x...> form of the B<-0> flag has been clarified, and the final section |
3304 |
|
|
on environment variables has been corrected and expanded (5.14.1). |
3305 |
|
|
|
3306 |
argrath |
1.8 |
=end original |
3307 |
|
|
|
3308 |
|
|
L<perlrun> は大幅に整理されました。 |
3309 |
|
|
最も注目するべき所は、B<-0> フラグの B<-0x...> 形式が明確化され、 |
3310 |
|
|
環境変数の最後の節が修正、拡張されました(5.14.1)。 |
3311 |
|
|
|
3312 |
argrath |
1.1 |
=back |
3313 |
|
|
|
3314 |
|
|
=head3 L<perlsub> |
3315 |
|
|
|
3316 |
|
|
=over |
3317 |
|
|
|
3318 |
|
|
=item * |
3319 |
|
|
|
3320 |
argrath |
1.8 |
=begin original |
3321 |
|
|
|
3322 |
argrath |
1.1 |
The ($;) prototype syntax, which has existed for rather a long time, is now |
3323 |
|
|
documented in L<perlsub>. It allows a unary function to have the same |
3324 |
|
|
precedence as a list operator. |
3325 |
|
|
|
3326 |
argrath |
1.8 |
=end original |
3327 |
|
|
|
3328 |
|
|
かなり長い間存在していた ($;) プロトタイプが L<perlsub> で文書化されました。 |
3329 |
|
|
リスト演算子と同じ優先順位を持つ単項関数が可能になります。 |
3330 |
|
|
|
3331 |
argrath |
1.1 |
=back |
3332 |
|
|
|
3333 |
|
|
=head3 L<perltie> |
3334 |
|
|
|
3335 |
|
|
=over |
3336 |
|
|
|
3337 |
|
|
=item * |
3338 |
|
|
|
3339 |
argrath |
1.8 |
=begin original |
3340 |
|
|
|
3341 |
argrath |
1.1 |
The required syntax for tying handles has been documented. |
3342 |
|
|
|
3343 |
argrath |
1.8 |
=end original |
3344 |
|
|
|
3345 |
|
|
ハンドルを tie するために必要な文法が文書化されました。 |
3346 |
|
|
|
3347 |
argrath |
1.1 |
=back |
3348 |
|
|
|
3349 |
|
|
=head3 L<perlvar> |
3350 |
|
|
|
3351 |
|
|
=over |
3352 |
|
|
|
3353 |
|
|
=item * |
3354 |
|
|
|
3355 |
argrath |
1.8 |
=begin original |
3356 |
|
|
|
3357 |
argrath |
1.1 |
The documentation for L<$!|perlvar/$!> has been corrected and clarified. |
3358 |
|
|
It used to state that $! could be C<undef>, which is not the case. It was |
3359 |
|
|
also unclear as to whether system calls set C's C<errno> or Perl's C<$!> |
3360 |
|
|
[perl #91614]. |
3361 |
|
|
|
3362 |
argrath |
1.8 |
=end original |
3363 |
|
|
|
3364 |
|
|
L<$!|perlvar/$!> の文書が修正され明確化されました。 |
3365 |
|
|
以前は $! は C<undef> になることがあると書かれていましたが、そうなることは |
3366 |
|
|
ありませんでした。 |
3367 |
|
|
また、システムコールが C の C<errno> を設定するのか Perl の C<$!> を |
3368 |
|
|
設定するのかが不明確でした [perl #91614]。 |
3369 |
|
|
|
3370 |
argrath |
1.1 |
=item * |
3371 |
|
|
|
3372 |
argrath |
1.8 |
=begin original |
3373 |
|
|
|
3374 |
argrath |
1.1 |
Documentation for L<$$|perlvar/$$> has been amended with additional |
3375 |
|
|
cautions regarding changing the process ID. |
3376 |
|
|
|
3377 |
argrath |
1.8 |
=end original |
3378 |
|
|
|
3379 |
|
|
L<$$|perlvar/$$> の文書は、プロセス ID の変更に関する追加の注意を |
3380 |
|
|
追記されました。 |
3381 |
|
|
|
3382 |
argrath |
1.1 |
=back |
3383 |
|
|
|
3384 |
|
|
=head3 Other Changes |
3385 |
|
|
|
3386 |
argrath |
1.9 |
(その他の変更) |
3387 |
|
|
|
3388 |
argrath |
1.1 |
=over 4 |
3389 |
|
|
|
3390 |
|
|
=item * |
3391 |
|
|
|
3392 |
argrath |
1.9 |
=begin original |
3393 |
|
|
|
3394 |
argrath |
1.1 |
L<perlxs> was extended with documentation on inline typemaps. |
3395 |
|
|
|
3396 |
argrath |
1.9 |
=end original |
3397 |
|
|
|
3398 |
|
|
L<perlxs> はインライン typemap の文書で拡張されました。 |
3399 |
|
|
|
3400 |
argrath |
1.1 |
=item * |
3401 |
|
|
|
3402 |
argrath |
1.9 |
=begin original |
3403 |
|
|
|
3404 |
argrath |
1.1 |
L<perlref> has a new L<Circular References|perlref/Circular References> |
3405 |
|
|
section explaining how circularities may not be freed and how to solve that |
3406 |
|
|
with weak references. |
3407 |
|
|
|
3408 |
argrath |
1.9 |
=end original |
3409 |
|
|
|
3410 |
|
|
L<perlref> に、なぜ循環性があると解放されないかと弱い参照を使って |
3411 |
|
|
解決する方法を説明した新しい章である |
3412 |
|
|
L<Circular References|perlref/Circular References> が追加されました。 |
3413 |
|
|
|
3414 |
argrath |
1.1 |
=item * |
3415 |
|
|
|
3416 |
argrath |
1.9 |
=begin original |
3417 |
|
|
|
3418 |
argrath |
1.1 |
Parts of L<perlapi> were clarified, and Perl equivalents of some C |
3419 |
|
|
functions have been added as an additional mode of exposition. |
3420 |
|
|
|
3421 |
argrath |
1.9 |
=end original |
3422 |
|
|
|
3423 |
|
|
L<perlapi> の一部が明確化され、and Perl equivalents of some C |
3424 |
|
|
functions have been added as an additional mode of exposition. |
3425 |
|
|
(TBT) |
3426 |
|
|
|
3427 |
argrath |
1.1 |
=item * |
3428 |
|
|
|
3429 |
argrath |
1.9 |
=begin original |
3430 |
|
|
|
3431 |
argrath |
1.1 |
A few parts of L<perlre> and L<perlrecharclass> were clarified. |
3432 |
|
|
|
3433 |
argrath |
1.9 |
=end original |
3434 |
|
|
|
3435 |
|
|
L<perlre> と L<perlrecharclass> のいくつかの部分が明確化されました。 |
3436 |
|
|
|
3437 |
argrath |
1.1 |
=back |
3438 |
|
|
|
3439 |
|
|
=head2 Removed Documentation |
3440 |
|
|
|
3441 |
argrath |
1.9 |
(削除された文書) |
3442 |
|
|
|
3443 |
argrath |
1.1 |
=head3 Old OO Documentation |
3444 |
|
|
|
3445 |
argrath |
1.9 |
(古い OO 文書) |
3446 |
|
|
|
3447 |
|
|
=begin original |
3448 |
|
|
|
3449 |
argrath |
1.1 |
All the old OO tutorials, perltoot, perltooc, and perlboot, have been |
3450 |
|
|
removed. The perlbot (bag of object tricks) document has been removed |
3451 |
|
|
as well. |
3452 |
|
|
|
3453 |
argrath |
1.9 |
=end original |
3454 |
|
|
|
3455 |
|
|
古い OO チュートリアルである perltoot, perltooc, perlboot は削除されました。 |
3456 |
|
|
perlbot (bag of object tricks) 文書も削除されました。 |
3457 |
|
|
|
3458 |
argrath |
1.1 |
=head3 Development Deltas |
3459 |
|
|
|
3460 |
argrath |
1.9 |
=begin original |
3461 |
|
|
|
3462 |
argrath |
1.1 |
The perldelta files for development releases are no longer packaged with |
3463 |
|
|
perl. These can still be found in the perl source code repository. |
3464 |
|
|
|
3465 |
argrath |
1.9 |
=end original |
3466 |
|
|
|
3467 |
|
|
開発リリースの perldelta ファイルは perl と共に |
3468 |
|
|
パッケージングされなくなりました。 |
3469 |
|
|
perl ソースコードレポジトリには残っています。 |
3470 |
|
|
|
3471 |
argrath |
1.1 |
=head1 Diagnostics |
3472 |
|
|
|
3473 |
argrath |
1.9 |
(診断メッセージ) |
3474 |
|
|
|
3475 |
|
|
=begin original |
3476 |
|
|
|
3477 |
argrath |
1.1 |
The following additions or changes have been made to diagnostic output, |
3478 |
|
|
including warnings and fatal error messages. For the complete list of |
3479 |
|
|
diagnostic messages, see L<perldiag>. |
3480 |
|
|
|
3481 |
argrath |
1.9 |
=end original |
3482 |
|
|
|
3483 |
|
|
以下の追加や変更が、警告や致命的エラーメッセージ含む診断出力に行われました。 |
3484 |
|
|
完全な診断メッセージの一覧については、L<perldiag> を参照してください。 |
3485 |
|
|
|
3486 |
argrath |
1.1 |
=head2 New Diagnostics |
3487 |
|
|
|
3488 |
argrath |
1.9 |
(新しい診断メッセージ) |
3489 |
|
|
|
3490 |
argrath |
1.1 |
=head3 New Errors |
3491 |
|
|
|
3492 |
argrath |
1.9 |
(新しいエラー) |
3493 |
|
|
|
3494 |
argrath |
1.1 |
=over 4 |
3495 |
|
|
|
3496 |
|
|
=item * |
3497 |
|
|
|
3498 |
|
|
L<Cannot set tied @DB::args|perldiag/"Cannot set tied @DB::args"> |
3499 |
|
|
|
3500 |
argrath |
1.9 |
=begin original |
3501 |
|
|
|
3502 |
argrath |
1.1 |
This error occurs when C<caller> tries to set C<@DB::args> but finds it |
3503 |
|
|
tied. Before this error was added, it used to crash instead. |
3504 |
|
|
|
3505 |
argrath |
1.9 |
=end original |
3506 |
|
|
|
3507 |
|
|
このエラーは、C<caller> が C<@DB::args> を設定しようとしたけれども |
3508 |
|
|
これが tie されていたときに起こります。 |
3509 |
|
|
このエラーが追加される前は、クラッシュしていました。 |
3510 |
|
|
|
3511 |
argrath |
1.1 |
=item * |
3512 |
|
|
|
3513 |
|
|
L<Cannot tie unreifiable array|perldiag/"Cannot tie unreifiable array"> |
3514 |
|
|
|
3515 |
argrath |
1.9 |
=begin original |
3516 |
|
|
|
3517 |
argrath |
1.1 |
This error is part of a safety check that the C<tie> operator does before |
3518 |
|
|
tying a special array like C<@_>. You should never see this message. |
3519 |
|
|
|
3520 |
argrath |
1.9 |
=end original |
3521 |
|
|
|
3522 |
|
|
このエラーは、C<@_> のような特殊配列を tie する前に C<tie> 演算子が行う |
3523 |
|
|
安全チェックの一部です。 |
3524 |
|
|
このメッセージを見ることは決してないはずです。 |
3525 |
|
|
|
3526 |
argrath |
1.1 |
=item * |
3527 |
|
|
|
3528 |
|
|
L<&CORE::%s cannot be called directly|perldiag/"&CORE::%s cannot be called directly"> |
3529 |
|
|
|
3530 |
argrath |
1.9 |
=begin original |
3531 |
|
|
|
3532 |
argrath |
1.1 |
This occurs when a subroutine in the C<CORE::> namespace is called |
3533 |
|
|
with C<&foo> syntax or through a reference. Some subroutines |
3534 |
|
|
in this package cannot yet be called that way, but must be |
3535 |
|
|
called as barewords. See L</Subroutines in the C<CORE> namespace>, above. |
3536 |
|
|
|
3537 |
argrath |
1.9 |
=end original |
3538 |
|
|
|
3539 |
|
|
これは、C<CORE::> 名前空間のサブルーチンが C<&foo> 文法またはリファレンスを |
3540 |
|
|
通して呼び出されたときに起こります。 |
3541 |
|
|
このパッケージの一部のサブルーチンはまだこのような方法では呼び出せず、 |
3542 |
|
|
裸の単語で呼び出さなければなりません。 |
3543 |
|
|
上述の L</Subroutines in the C<CORE> namespace> を参照してください。 |
3544 |
|
|
|
3545 |
argrath |
1.1 |
=item * |
3546 |
|
|
|
3547 |
|
|
L<Source filters apply only to byte streams|perldiag/"Source filters apply only to byte streams"> |
3548 |
|
|
|
3549 |
argrath |
1.9 |
=begin original |
3550 |
|
|
|
3551 |
argrath |
1.1 |
This new error occurs when you try to activate a source filter (usually by |
3552 |
|
|
loading a source filter module) within a string passed to C<eval> under the |
3553 |
|
|
C<unicode_eval> feature. |
3554 |
|
|
|
3555 |
argrath |
1.9 |
=end original |
3556 |
|
|
|
3557 |
|
|
この新しいエラーは、C<unicode_eval> 機能が有効の時に C<eval> に渡された |
3558 |
|
|
文字列の中でソースフィルタを(通常はソースフィルタモジュールを読み込むことで) |
3559 |
|
|
起動しようとした場合に起こります。 |
3560 |
|
|
|
3561 |
argrath |
1.1 |
=back |
3562 |
|
|
|
3563 |
|
|
=head3 New Warnings |
3564 |
|
|
|
3565 |
argrath |
1.9 |
(新しい警告) |
3566 |
|
|
|
3567 |
argrath |
1.1 |
=over 4 |
3568 |
|
|
|
3569 |
|
|
=item * |
3570 |
|
|
|
3571 |
|
|
L<defined(@array) is deprecated|perldiag/"defined(@array) is deprecated"> |
3572 |
|
|
|
3573 |
argrath |
1.9 |
=begin original |
3574 |
|
|
|
3575 |
argrath |
1.1 |
The long-deprecated C<defined(@array)> now also warns for package variables. |
3576 |
|
|
Previously it only issued a warning for lexical variables. |
3577 |
|
|
|
3578 |
argrath |
1.9 |
=end original |
3579 |
|
|
|
3580 |
|
|
長い間非推奨となっている C<defined(@array)> は、パッケージ変数に対しても |
3581 |
|
|
警告するようになりました。 |
3582 |
|
|
以前はレキシカル変数に対してのみ警告を出していました。 |
3583 |
|
|
|
3584 |
argrath |
1.1 |
=item * |
3585 |
|
|
|
3586 |
|
|
L<length() used on %s|perldiag/length() used on %s> |
3587 |
|
|
|
3588 |
argrath |
1.9 |
=begin original |
3589 |
|
|
|
3590 |
argrath |
1.1 |
This new warning occurs when C<length> is used on an array or hash, instead |
3591 |
|
|
of C<scalar(@array)> or C<scalar(keys %hash)>. |
3592 |
|
|
|
3593 |
argrath |
1.9 |
=end original |
3594 |
|
|
|
3595 |
|
|
この新しい警告は、C<scalar(@array)> や C<scalar(keys %hash)> ではなく、 |
3596 |
|
|
C<length> が配列やハッシュに使われるときに発生します。 |
3597 |
|
|
|
3598 |
argrath |
1.1 |
=item * |
3599 |
|
|
|
3600 |
|
|
L<lvalue attribute %s already-defined subroutine|perldiag/"lvalue attribute %s already-defined subroutine"> |
3601 |
|
|
|
3602 |
argrath |
1.9 |
=begin original |
3603 |
|
|
|
3604 |
argrath |
1.1 |
L<attributes.pm|attributes> now emits this warning when the :lvalue |
3605 |
|
|
attribute is applied to a Perl subroutine that has already been defined, as |
3606 |
|
|
doing so can have unexpected side-effects. |
3607 |
|
|
|
3608 |
argrath |
1.9 |
=end original |
3609 |
|
|
|
3610 |
|
|
L<attributes.pm|attributes> は、:lvalue 属性が既に定義されている |
3611 |
|
|
Perl サブルーチンに適用されると出力されます; なぜならそうすると想定外の |
3612 |
|
|
副作用があるかもしれないからです。 |
3613 |
|
|
|
3614 |
argrath |
1.1 |
=item * |
3615 |
|
|
|
3616 |
|
|
L<overload arg '%s' is invalid|perldiag/"overload arg '%s' is invalid"> |
3617 |
|
|
|
3618 |
argrath |
1.9 |
=begin original |
3619 |
|
|
|
3620 |
argrath |
1.1 |
This warning, in the "overload" category, is produced when the overload |
3621 |
|
|
pragma is given an argument it doesn't recognize, presumably a mistyped |
3622 |
|
|
operator. |
3623 |
|
|
|
3624 |
argrath |
1.9 |
=end original |
3625 |
|
|
|
3626 |
|
|
"overload" カテゴリに入るこの警告は、overload プラグマが (おそらくは |
3627 |
|
|
ミスタイプした演算子で) 認識できない引数を指定されたときに発生します。 |
3628 |
|
|
|
3629 |
argrath |
1.1 |
=item * |
3630 |
|
|
|
3631 |
|
|
L<$[ used in %s (did you mean $] ?)|perldiag/"$[ used in %s (did you mean $] ?)"> |
3632 |
|
|
|
3633 |
argrath |
1.9 |
=begin original |
3634 |
|
|
|
3635 |
argrath |
1.1 |
This new warning exists to catch the mistaken use of C<$[> in version |
3636 |
|
|
checks. C<$]>, not C<$[>, contains the version number. |
3637 |
|
|
|
3638 |
argrath |
1.9 |
=end original |
3639 |
|
|
|
3640 |
|
|
この新しい警告はバージョンチェックでの C<$[> の間違った使用法を |
3641 |
|
|
捕捉するために存在します。 |
3642 |
|
|
バージョン番号は C<$[> ではなく C<$]> に含まれています。 |
3643 |
|
|
|
3644 |
argrath |
1.1 |
=item * |
3645 |
|
|
|
3646 |
|
|
L<Useless assignment to a temporary|perldiag/"Useless assignment to a temporary"> |
3647 |
|
|
|
3648 |
argrath |
1.9 |
=begin original |
3649 |
|
|
|
3650 |
argrath |
1.1 |
Assigning to a temporary scalar returned |
3651 |
|
|
from an lvalue subroutine now produces this |
3652 |
|
|
warning [perl #31946]. |
3653 |
|
|
|
3654 |
argrath |
1.9 |
=end original |
3655 |
|
|
|
3656 |
|
|
左辺値サブルーチンから返された一時スカラに代入するとこの警告が |
3657 |
|
|
出力されるようになりました [perl #31946]。 |
3658 |
|
|
|
3659 |
argrath |
1.1 |
=item * |
3660 |
|
|
|
3661 |
|
|
L<Useless use of \E|perldiag/"Useless use of \E"> |
3662 |
|
|
|
3663 |
argrath |
1.9 |
=begin original |
3664 |
|
|
|
3665 |
argrath |
1.1 |
C<\E> does nothing unless preceded by C<\Q>, C<\L> or C<\U>. |
3666 |
|
|
|
3667 |
argrath |
1.9 |
=end original |
3668 |
|
|
|
3669 |
|
|
C<\Q>, C<\L>, C<\U> のいずれかが前にない場合、C<\E> は何もしません。 |
3670 |
|
|
|
3671 |
argrath |
1.1 |
=back |
3672 |
|
|
|
3673 |
|
|
=head2 Removed Errors |
3674 |
|
|
|
3675 |
argrath |
1.9 |
(削除されたエラー) |
3676 |
|
|
|
3677 |
argrath |
1.1 |
=over |
3678 |
|
|
|
3679 |
|
|
=item * |
3680 |
|
|
|
3681 |
|
|
"sort is now a reserved word" |
3682 |
|
|
|
3683 |
argrath |
1.10 |
=begin original |
3684 |
|
|
|
3685 |
argrath |
1.1 |
This error used to occur when C<sort> was called without arguments, |
3686 |
|
|
followed by C<;> or C<)>. (E.g., C<sort;> would die, but C<{sort}> was |
3687 |
|
|
OK.) This error message was added in Perl 3 to catch code like |
3688 |
|
|
C<close(sort)> which would no longer work. More than two decades later, |
3689 |
|
|
this message is no longer appropriate. Now C<sort> without arguments is |
3690 |
|
|
always allowed, and returns an empty list, as it did in those cases |
3691 |
|
|
where it was already allowed [perl #90030]. |
3692 |
|
|
|
3693 |
argrath |
1.10 |
=end original |
3694 |
|
|
|
3695 |
|
|
このエラーは C<sort> が引数なしで呼び出され、その後に C<;> か C<)> が |
3696 |
|
|
続いていた場合に発生していました。 |
3697 |
|
|
(例えば C<sort;> は die しますが、C<{sort}> は OK です。) |
3698 |
|
|
このエラーは、もはや動作しない C<close(sort)> のようなコードを捕捉するために |
3699 |
|
|
Perl 3 で追加されました。 |
3700 |
|
|
20 年以上経って、このメッセージはもはや適切ではなくなりました。 |
3701 |
|
|
引数なしの C<sort> は常に許されるようになり、今まで許されていた場合と |
3702 |
|
|
同じように、空リストを返します [perl #90030]。 |
3703 |
|
|
|
3704 |
argrath |
1.1 |
=back |
3705 |
|
|
|
3706 |
|
|
=head2 Changes to Existing Diagnostics |
3707 |
|
|
|
3708 |
argrath |
1.9 |
(既存の診断メッセージの変更) |
3709 |
|
|
|
3710 |
argrath |
1.1 |
=over 4 |
3711 |
|
|
|
3712 |
|
|
=item * |
3713 |
|
|
|
3714 |
argrath |
1.11 |
=begin original |
3715 |
|
|
|
3716 |
argrath |
1.1 |
The "Applying pattern match..." or similar warning produced when an |
3717 |
|
|
array or hash is on the left-hand side of the C<=~> operator now |
3718 |
|
|
mentions the name of the variable. |
3719 |
|
|
|
3720 |
argrath |
1.11 |
=end original |
3721 |
|
|
|
3722 |
|
|
配列やハッシュが C<=~> 演算子の左側にあるときに出力される |
3723 |
|
|
"Applying pattern match..." または同様の警告は、変数名を |
3724 |
|
|
出力するようになりました。 |
3725 |
|
|
|
3726 |
argrath |
1.1 |
=item * |
3727 |
|
|
|
3728 |
argrath |
1.11 |
=begin original |
3729 |
|
|
|
3730 |
argrath |
1.1 |
The "Attempt to free non-existent shared string" has had the spelling |
3731 |
|
|
of "non-existent" corrected to "nonexistent". It was already listed |
3732 |
|
|
with the correct spelling in L<perldiag>. |
3733 |
|
|
|
3734 |
argrath |
1.11 |
=end original |
3735 |
|
|
|
3736 |
|
|
"Attempt to free non-existent shared string" は "non-existent" という綴りを |
3737 |
|
|
"nonexistent" に変更しました。 |
3738 |
|
|
これは L<perldiag> では既に正しい綴りになっていました。 |
3739 |
|
|
|
3740 |
argrath |
1.1 |
=item * |
3741 |
|
|
|
3742 |
argrath |
1.11 |
=begin original |
3743 |
|
|
|
3744 |
argrath |
1.1 |
The error messages for using C<default> and C<when> outside of a |
3745 |
|
|
topicalizer have been standardised to match the messages for C<continue> |
3746 |
|
|
and loop controls. They now read 'Can't "default" outside a |
3747 |
|
|
topicalizer' and 'Can't "when" outside a topicalizer'. They both used |
3748 |
|
|
to be 'Can't use when() outside a topicalizer' [perl #91514]. |
3749 |
|
|
|
3750 |
argrath |
1.11 |
=end original |
3751 |
|
|
|
3752 |
|
|
解析器の外側で C<default> や C<when> を使ったときのエラーメッセージは |
3753 |
|
|
C<continue> やループ制御のときのメッセージと一致するように |
3754 |
|
|
標準化されました。 |
3755 |
|
|
'Can't "default" outside a topicalizer' と |
3756 |
|
|
'Can't "when" outside a topicalizer' になりました。 |
3757 |
|
|
以前は 'Can't use when() outside a topicalizer' でした [perl #91514]。 |
3758 |
|
|
|
3759 |
argrath |
1.1 |
=item * |
3760 |
|
|
|
3761 |
argrath |
1.11 |
=begin original |
3762 |
|
|
|
3763 |
argrath |
1.1 |
The message, "Code point 0x%X is not Unicode, no properties match it; |
3764 |
|
|
all inverse properties do" has been changed to "Code point 0x%X is not |
3765 |
|
|
Unicode, all \p{} matches fail; all \P{} matches succeed". |
3766 |
|
|
|
3767 |
argrath |
1.11 |
=end original |
3768 |
|
|
|
3769 |
|
|
"Code point 0x%X is not Unicode, no properties match it; |
3770 |
|
|
all inverse properties do" というメッセージは "Code point 0x%X is not |
3771 |
|
|
Unicode, all \p{} matches fail; all \P{} matches succeed" に |
3772 |
|
|
変更されました。 |
3773 |
|
|
|
3774 |
argrath |
1.1 |
=item * |
3775 |
|
|
|
3776 |
argrath |
1.11 |
=begin original |
3777 |
|
|
|
3778 |
argrath |
1.1 |
Redefinition warnings for constant subroutines used to be mandatory, |
3779 |
|
|
even occurring under C<no warnings>. Now they respect the L<warnings> |
3780 |
|
|
pragma. |
3781 |
|
|
|
3782 |
argrath |
1.11 |
=end original |
3783 |
|
|
|
3784 |
|
|
定数サブルーチンの再定義警告は、たとえ C<no warnings> のもとでも |
3785 |
|
|
強制的に発生していました。 |
3786 |
|
|
これは L<warnings> プラグマに従うようになりました。 |
3787 |
|
|
|
3788 |
argrath |
1.1 |
=item * |
3789 |
|
|
|
3790 |
argrath |
1.11 |
=begin original |
3791 |
|
|
|
3792 |
argrath |
1.1 |
The "glob failed" warning message is now suppressible via C<no warnings> |
3793 |
|
|
[perl #111656]. |
3794 |
|
|
|
3795 |
argrath |
1.11 |
=end original |
3796 |
|
|
|
3797 |
|
|
"glob failed" 警告メッセージは C<no warnings> で抑制できるようになりました |
3798 |
|
|
[perl #111656]。 |
3799 |
|
|
|
3800 |
argrath |
1.1 |
=item * |
3801 |
|
|
|
3802 |
argrath |
1.11 |
=begin original |
3803 |
|
|
|
3804 |
argrath |
1.1 |
The L<Invalid version format|perldiag/"Invalid version format (%s)"> |
3805 |
|
|
error message now says "negative version number" within the parentheses, |
3806 |
|
|
rather than "non-numeric data", for negative numbers. |
3807 |
|
|
|
3808 |
argrath |
1.11 |
=end original |
3809 |
|
|
|
3810 |
|
|
L<Invalid version format|perldiag/"Invalid version format (%s)"> エラー |
3811 |
|
|
メッセージは、負数の場合はかっこの中は "non-numeric data" ではなく |
3812 |
|
|
"negative version number" と出力されるようになりました。 |
3813 |
|
|
|
3814 |
argrath |
1.1 |
=item * |
3815 |
|
|
|
3816 |
argrath |
1.11 |
=begin original |
3817 |
|
|
|
3818 |
argrath |
1.1 |
The two warnings |
3819 |
|
|
L<Possible attempt to put comments in qw() list|perldiag/"Possible attempt to put comments in qw() list"> |
3820 |
|
|
and |
3821 |
|
|
L<Possible attempt to separate words with commas|perldiag/"Possible attempt to separate words with commas"> |
3822 |
|
|
are no longer mutually exclusive: the same C<qw> construct may produce |
3823 |
|
|
both. |
3824 |
|
|
|
3825 |
argrath |
1.11 |
=end original |
3826 |
|
|
|
3827 |
|
|
L<Possible attempt to put comments in qw() list|perldiag/"Possible attempt to put comments in qw() list"> |
3828 |
|
|
と |
3829 |
|
|
L<Possible attempt to separate words with commas|perldiag/"Possible attempt to separate words with commas"> |
3830 |
|
|
の二つの警告は相互に排他的ではなくなりました: 同じ C<qw> 構文が両方を |
3831 |
|
|
出力することがあります。 |
3832 |
|
|
|
3833 |
argrath |
1.1 |
=item * |
3834 |
|
|
|
3835 |
argrath |
1.11 |
=begin original |
3836 |
|
|
|
3837 |
argrath |
1.1 |
The uninitialized warning for C<y///r> when C<$_> is implicit and |
3838 |
|
|
undefined now mentions the variable name, just like the non-/r variation |
3839 |
|
|
of the operator. |
3840 |
|
|
|
3841 |
argrath |
1.11 |
=end original |
3842 |
|
|
|
3843 |
|
|
C<$_> が暗黙で未定義のときの C<y///r> の未初期化警告は、非 /r 系の |
3844 |
|
|
演算子と同様に、変数名を出力するようになりました。 |
3845 |
|
|
|
3846 |
argrath |
1.1 |
=item * |
3847 |
|
|
|
3848 |
| |