@@ -1312,6 +1312,17 @@ msgid ""
1312
1312
"annotations. For example, use ``annotation_format=annotationlib.Format."
1313
1313
"STRING`` to return annotations in string format."
1314
1314
msgstr ""
1315
+ "アノテーションのいくつかが (たとえば ``from __future__ import annotations`` "
1316
+ "が使われていることを理由に) 文字列である場合、 :func:`signature` は :func:"
1317
+ "`annotationlib.get_annotations` を使って「非文字列化」すなわち文字列アノテー"
1318
+ "ションを解決して本来のアノテーションに戻すことを試みます。アノテーションの解"
1319
+ "決を行う際には *globals*, *locals*, および *eval_str* パラメータが :func:`!"
1320
+ "annotationlib.get_annotations` に渡されます; これらのパラメータを使う方法につ"
1321
+ "いての説明は :func:`!annotationlib.get_annotations` のドキュメンテーションを"
1322
+ "参照してください。返されるアノテーションの形式を制御するため、 "
1323
+ "*annotation_format* パラメータには :class:`annotationlib.Format` 列挙型のメン"
1324
+ "バーを渡すことができます。たとえばアノテーションを文字列形式で返すためには "
1325
+ "``annotation_format=annotationlib.Format.STRING`` を使ってください。"
1315
1326
1316
1327
#: ../../library/inspect.rst:752
1317
1328
msgid ""
@@ -1321,35 +1332,52 @@ msgid ""
1321
1332
"call(s) to un-stringize the annotations in :func:`annotationlib."
1322
1333
"get_annotations` could potentially raise any kind of exception."
1323
1334
msgstr ""
1335
+ "シグネチャを提供できない場合は :exc:`ValueError` 例外を送出します。またオブ"
1336
+ "ジェクトの型がサポートされていない場合は :exc:`TypeError` 例外を送出します。"
1337
+ "さらに、アノテーションが文字列化されており、 *eval_str* が偽でない場合、アノ"
1338
+ "テーションを「非文字列化」するために :func:`annotationlib.get_annotations` 内"
1339
+ "部で呼ばれる ``eval()`` により、いかなる種類の例外も送出される可能性がありま"
1340
+ "す。"
1324
1341
1325
1342
#: ../../library/inspect.rst:758
1326
1343
msgid ""
1327
1344
"A slash (/) in the signature of a function denotes that the parameters prior "
1328
1345
"to it are positional-only. For more info, see :ref:`the FAQ entry on "
1329
1346
"positional-only parameters <faq-positional-only-arguments>`."
1330
1347
msgstr ""
1348
+ "関数シグネチャにおけるスラッシュ (/) は、それより前のパラメータが位置専用引数"
1349
+ "であることを示します。より詳しい情報は、 :ref:`位置専用引数に関する FAQ エン"
1350
+ "トリ <faq-positional-only-arguments>` を参照してください。"
1331
1351
1332
1352
#: ../../library/inspect.rst:762
1333
1353
msgid ""
1334
1354
"The *follow_wrapped* parameter was added. Pass ``False`` to get a signature "
1335
1355
"of *callable* specifically (``callable.__wrapped__`` will not be used to "
1336
1356
"unwrap decorated callables.)"
1337
1357
msgstr ""
1358
+ "*follow_wrapped* パラメータが追加されました。parameter was added. 特に "
1359
+ "*callable* そのものについてのシグネチャを取得するためには ``False`` を指定し"
1360
+ "てください (そうすることで、デコレータで修飾された呼び出し可能オブジェクトに"
1361
+ "対して``callable.__wrapped__`` が使われなくなります)。"
1338
1362
1339
1363
#: ../../library/inspect.rst:768 ../../library/inspect.rst:904
1340
1364
msgid "The *globals*, *locals*, and *eval_str* parameters were added."
1341
- msgstr ""
1365
+ msgstr "*globals*, *locals*, および *eval_str* パラメータが追加されました。 "
1342
1366
1343
1367
#: ../../library/inspect.rst:771
1344
1368
msgid "The *annotation_format* parameter was added."
1345
- msgstr ""
1369
+ msgstr "*annotation_format* パラメータが追加されました。 "
1346
1370
1347
1371
#: ../../library/inspect.rst:776
1348
1372
msgid ""
1349
1373
"Some callables may not be introspectable in certain implementations of "
1350
1374
"Python. For example, in CPython, some built-in functions defined in C "
1351
1375
"provide no metadata about their arguments."
1352
1376
msgstr ""
1377
+ "いくつかの呼び出し可能オブジェクトは、ある Python 実装の下ではイントロスペク"
1378
+ "ション (実行時オブジェクト調査) ができないかもしれません。たとえば CPython で"
1379
+ "は、 C で定義されたいくつかの組み込み関数はそれらの引数に関するメタデータを提"
1380
+ "供しません。"
1353
1381
1354
1382
#: ../../library/inspect.rst:782
1355
1383
msgid ""
@@ -1358,13 +1386,21 @@ msgid ""
1358
1386
"and are subject to unannounced changes. Consult the source code for current "
1359
1387
"semantics."
1360
1388
msgstr ""
1389
+ "渡されたオブジェクトが :attr:`!__signature__` 属性を持つ場合、それにもとづい"
1390
+ "てシグネチャを作ることができるかもしれません。厳密なセマンティクスは実装レベ"
1391
+ "ルの詳細であり、予告なく変更される可能性があります。現在のセマンティクスにつ"
1392
+ "いてはソースコードをを参照してください。"
1361
1393
1362
1394
#: ../../library/inspect.rst:790
1363
1395
msgid ""
1364
1396
"A :class:`!Signature` object represents the call signature of a function and "
1365
1397
"its return annotation. For each parameter accepted by the function it "
1366
1398
"stores a :class:`Parameter` object in its :attr:`parameters` collection."
1367
1399
msgstr ""
1400
+ ":class:`!Signature` オブジェクトは、関数の呼び出しシグネチャと戻り値のアノ"
1401
+ "テーションを表現します。このオブジェクトは :attr:`parameters` 集合として、関"
1402
+ "数が受け取るパラメータそれぞれについての :class:`Parameter` オブジェクトを保"
1403
+ "存します。"
1368
1404
1369
1405
#: ../../library/inspect.rst:795
1370
1406
msgid ""
0 commit comments