@@ -13,7 +13,7 @@ msgid ""
1313msgstr ""
1414"Project-Id-Version : Python 3.12\n "
1515"Report-Msgid-Bugs-To : \n "
16- "POT-Creation-Date : 2023-12-15 14:14 +0000\n "
16+ "POT-Creation-Date : 2023-12-22 14:13 +0000\n "
1717"PO-Revision-Date : 2021-06-28 01:10+0000\n "
1818"Last-Translator : Arihiro TAKASE, 2023\n "
1919"Language-Team : Japanese (https://app.transifex.com/python-doc/teams/5390/ "
@@ -34,15 +34,11 @@ msgstr "**ソースコード:** :source:`Lib/numbers.py`"
3434
3535#: ../../library/numbers.rst:11
3636msgid ""
37- "The :mod:`numbers` module (:pep:`3141`) defines a hierarchy of numeric :term :"
38- "`abstract base classes <abstract base class>` which progressively define "
39- "more operations. None of the types defined in this module are intended to "
40- "be instantiated."
37+ "The :mod:`! numbers` module (:pep:`3141`) defines a hierarchy of numeric :"
38+ "term: `abstract base classes <abstract base class>` which progressively "
39+ "define more operations. None of the types defined in this module are "
40+ "intended to be instantiated."
4141msgstr ""
42- ":mod:`numbers` モジュール (:pep:`3141`) は数の :term:`抽象基底クラス "
43- "<abstract base class>` の階層を定義します。この階層では、さらに多くの演算が順"
44- "番に定義されます。このモジュールで定義される型はどれもインスタンス化を想定し"
45- "ていません。"
4642
4743#: ../../library/numbers.rst:18
4844msgid ""
@@ -88,10 +84,9 @@ msgstr ""
8884
8985#: ../../library/numbers.rst:48
9086msgid ""
91- "To :class:`Complex`, :class:`Real` adds the operations that work on real "
87+ "To :class:`Complex`, :class:`! Real` adds the operations that work on real "
9288"numbers."
9389msgstr ""
94- ":class:`Real` は、:class:`Complex` 上に、 実数に対して行える演算を加えます。"
9590
9691#: ../../library/numbers.rst:51
9792msgid ""
@@ -185,16 +180,11 @@ msgid ""
185180"We want to implement the arithmetic operations so that mixed-mode operations "
186181"either call an implementation whose author knew about the types of both "
187182"arguments, or convert both to the nearest built in type and do the operation "
188- "there. For subtypes of :class:`Integral`, this means that :meth:`__add__` "
189- "and :meth:`__radd__` should be defined as::"
183+ "there. For subtypes of :class:`Integral`, this means that :meth:`~object. "
184+ "__add__` and :meth:`~object. __radd__` should be defined as::"
190185msgstr ""
191- "算術演算を実装する際には、型混合(mixed-mode)演算を行うと、作者が両方の引数の"
192- "型について知っているような実装を呼び出すか、両方の引数をそれぞれ最も似ている"
193- "組み込み型に変換してその型で演算を行うか、どちらになるのが望ましい実装です。"
194- "つまり、 :class:`Integral` のサブタイプに対しては :meth:`__add__` と :meth:"
195- "`__radd__` を次のように定義するべきです::"
196186
197- #: ../../library/numbers.rst:156
187+ #: ../../library/numbers.rst:157
198188msgid ""
199189"There are 5 different cases for a mixed-type operation on subclasses of :"
200190"class:`Complex`. I'll refer to all of the above code that doesn't refer to "
@@ -208,43 +198,35 @@ msgstr ""
208198"ブタイプである ``A`` のインスタンス (``a : A <: Complex``)、同様に ``b : B "
209199"<: Complex`` として、 ``a + b`` を考えます:"
210200
211- #: ../../library/numbers.rst:163
212- msgid "If ``A`` defines an :meth:`__add__` which accepts ``b``, all is well."
201+ #: ../../library/numbers.rst:164
202+ msgid ""
203+ "If ``A`` defines an :meth:`~object.__add__` which accepts ``b``, all is well."
213204msgstr ""
214- "``A`` が ``b`` を受け付ける :meth:`__add__` を定義している場合、何も問題はあ"
215- "りません。"
216205
217- #: ../../library/numbers.rst:165
206+ #: ../../library/numbers.rst:166
218207msgid ""
219208"If ``A`` falls back to the boilerplate code, and it were to return a value "
220- "from :meth:`__add__`, we'd miss the possibility that ``B`` defines a more "
221- "intelligent :meth:`__radd__`, so the boilerplate should return :const :"
222- "`NotImplemented` from :meth:`__add__`. (Or ``A`` may not implement :meth :"
223- "` __add__` at all.)"
209+ "from :meth:`~object. __add__`, we'd miss the possibility that ``B`` defines a "
210+ "more intelligent :meth:`~object. __radd__`, so the boilerplate should return :"
211+ "const: `NotImplemented` from :meth:`! __add__`. (Or ``A`` may not implement :"
212+ "meth:`! __add__` at all.)"
224213msgstr ""
225- "``A`` でボイラープレート部分に落ち込み、その結果 :meth:`__add__` が値を返すな"
226- "らば、 ``B`` に良く考えられた :meth:`__radd__` が定義されている可能性を見逃し"
227- "てしまいますので、ボイラープレートは :meth:`__add__` から :const:"
228- "`NotImplemented` を返すのが良いでしょう。(若しくは、 ``A`` はまったく :meth:"
229- "`__add__` を実装すべきではなかったかもしれません。)"
230214
231- #: ../../library/numbers.rst:171
215+ #: ../../library/numbers.rst:172
232216msgid ""
233- "Then ``B``'s :meth:`__radd__` gets a chance. If it accepts ``a``, all is "
234- "well."
217+ "Then ``B``'s :meth:`~object. __radd__` gets a chance. If it accepts ``a``, "
218+ "all is well."
235219msgstr ""
236- "そうすると、 ``B`` の :meth:`__radd__` にチャンスが巡ってきます。ここで "
237- "``a`` が受け付けられるならば、結果は上々です。"
238220
239- #: ../../library/numbers.rst:173
221+ #: ../../library/numbers.rst:174
240222msgid ""
241223"If it falls back to the boilerplate, there are no more possible methods to "
242224"try, so this is where the default implementation should live."
243225msgstr ""
244226"ここでボイラープレートに落ち込むならば、もう他に試すべきメソッドはありません"
245227"ので、デフォルト実装の出番です。"
246228
247- #: ../../library/numbers.rst:176
229+ #: ../../library/numbers.rst:177
248230msgid ""
249231"If ``B <: A``, Python tries ``B.__radd__`` before ``A.__add__``. This is ok, "
250232"because it was implemented with knowledge of ``A``, so it can handle those "
@@ -254,17 +236,15 @@ msgstr ""
254236"ます。これで良い理由は、 ``A`` についての知識を持って実装しており、 :class:"
255237"`Complex` に委ねる前にこれらのインスタンスを扱えるはずだからです。"
256238
257- #: ../../library/numbers.rst:181
239+ #: ../../library/numbers.rst:182
258240msgid ""
259241"If ``A <: Complex`` and ``B <: Real`` without sharing any other knowledge, "
260242"then the appropriate shared operation is the one involving the built in :"
261- "class:`complex`, and both :meth:`__radd__` s land there, so ``a+b == b+a``."
243+ "class:`complex`, and both :meth:`~object.__radd__` s land there, so ``a+b == "
244+ "b+a``."
262245msgstr ""
263- "もし ``A <: Complex`` かつ ``B <: Real`` で他に共有された知識が無いならば、適"
264- "切な共通の演算は組み込みの :class:`complex` を使ったものになり、どちらの :"
265- "meth:`__radd__` ともそこに着地するでしょうから、 ``a+b == b+a`` です。"
266246
267- #: ../../library/numbers.rst:186
247+ #: ../../library/numbers.rst:187
268248msgid ""
269249"Because most of the operations on any given type will be very similar, it "
270250"can be useful to define a helper function which generates the forward and "
0 commit comments