@@ -1630,17 +1630,21 @@ msgid ""
1630
1630
"compared within and across their types. They compare lexicographically "
1631
1631
"using the numeric values of their elements."
1632
1632
msgstr ""
1633
+ "バイナリシーケンス (:class:`bytes` または :class:`bytearray` のインスタンス) は、同じ型どうしでも別の型とでも比較できます。\n"
1634
+ "比較は要素の数としての値を使った辞書順で行われます。"
1633
1635
1634
1636
#: ../../reference/expressions.rst:1390
1635
1637
msgid ""
1636
1638
"Strings (instances of :class:`str`) compare lexicographically using the "
1637
1639
"numerical Unicode code points (the result of the built-in function "
1638
1640
":func:`ord`) of their characters. [#]_"
1639
1641
msgstr ""
1642
+ "文字列 (:class:`str` のインスタンス) の比較は、文字の Unicode のコードポイントの数としての値 (組み込み関数 "
1643
+ ":func:`ord` の返り値) を使った辞書順で行われます。 [#]_"
1640
1644
1641
1645
#: ../../reference/expressions.rst:1394
1642
1646
msgid "Strings and binary sequences cannot be directly compared."
1643
- msgstr ""
1647
+ msgstr "文字列とバイナリシーケンスは直接には比較できません。 "
1644
1648
1645
1649
#: ../../reference/expressions.rst:1396
1646
1650
msgid ""
@@ -1650,12 +1654,14 @@ msgid ""
1650
1654
"types results in inequality, and ordering comparison across these types "
1651
1655
"raises :exc:`TypeError`."
1652
1656
msgstr ""
1657
+ "シーケンス (:class:`tuple`, :class:`list`, or :class:`range` のインスタンス) の比較は、同じ型どうしでしか行えず、 range は順序比較をサポートしていません。\n"
1658
+ "異なる型どうしの等価比較の結果は等価でないとなり、異なる型どうしの順序比較は :exc:`TypeError` を送出します。"
1653
1659
1654
1660
#: ../../reference/expressions.rst:1402
1655
1661
msgid ""
1656
1662
"Sequences compare lexicographically using comparison of corresponding "
1657
1663
"elements, whereby reflexivity of the elements is enforced."
1658
- msgstr ""
1664
+ msgstr "シーケンスの比較は、要素の反射性があるものとして、対応する要素どうしの比較を使って辞書順で行われます。 "
1659
1665
1660
1666
#: ../../reference/expressions.rst:1405
1661
1667
msgid ""
@@ -1669,6 +1675,10 @@ msgid ""
1669
1675
"not-a-number values for example result in the following comparison behavior "
1670
1676
"when used in a list::"
1671
1677
msgstr ""
1678
+ "要素の反射性が強制されていると、コレクションの比較ではコレクションの要素 ``x`` に対して ``x == x`` が常に真だと仮定します。\n"
1679
+ "この仮定に基づいて、最初に要素の同一性が比較され、同一でない要素どうしに対してのみ要素の比較が行われます。\n"
1680
+ "この手法は、比較される要素が反射的な場合、厳密な要素比較と同じ結果をもたらします。\n"
1681
+ "反射的でない要素では厳密な要素比較と異なる結果になり、驚くかもしれません: 例えば、反射的でない非数値がリストで使われたとき、比較の振る舞いは次のような結果になります::"
1672
1682
1673
1683
#: ../../reference/expressions.rst:1423
1674
1684
msgid ""
@@ -1692,6 +1702,8 @@ msgid ""
1692
1702
"shorter collection is ordered first (for example, ``[1,2] < [1,2,3]`` is "
1693
1703
"true)."
1694
1704
msgstr ""
1705
+ "順序比較をサポートしているコレクションの順序は、最初の等価でない要素の順序と同じになります (例えば、 ``[1,2,x] <= [1,2,y]`` は ``x <= y``と同じ値になります)。\n"
1706
+ "対応する要素が存在しない場合、短い方のコレクションの方が先の順序となります (例えば、 ``[1,2] < [1,2,3]`` は真です)。"
1695
1707
1696
1708
#: ../../reference/expressions.rst:1436
1697
1709
msgid ""
@@ -1705,13 +1717,14 @@ msgstr ""
1705
1717
#: ../../reference/expressions.rst:1440
1706
1718
msgid ""
1707
1719
"Order comparisons (``<``, ``>``, ``<=``, and ``>=``) raise :exc:`TypeError`."
1708
- msgstr ""
1720
+ msgstr "順序比較 (``<``, ``>``, ``<=``, ``>=``) は :exc:`TypeError` を送出します。 "
1709
1721
1710
1722
#: ../../reference/expressions.rst:1442
1711
1723
msgid ""
1712
1724
"Sets (instances of :class:`set` or :class:`frozenset`) can be compared "
1713
1725
"within and across their types."
1714
1726
msgstr ""
1727
+ "集合 (:class:`set` または :class:`frozenset` のインスタンス) の比較は、これらの型の範囲で異なる型とも行えます。"
1715
1728
1716
1729
#: ../../reference/expressions.rst:1445
1717
1730
msgid ""
@@ -1723,16 +1736,19 @@ msgid ""
1723
1736
":func:`max`, and :func:`sorted` produce undefined results given a list of "
1724
1737
"sets as inputs)."
1725
1738
msgstr ""
1739
+ "集合には、部分集合あるいは上位集合かどうかを基準とする順序比較が定義されています。\n"
1740
+ "この関係は全順序を定義しません (例えば、 ``{1,2}`` と ``{2,3}`` という2つの集合は片方がもう一方の部分集合でもなく上位集合でもありません)。\n"
1741
+ "従って、集合は全順序性に依存する関数の引数として適切ではありません (例えば、 :func:`min`, :func:`max`, :func:`sorted` は集合のリストを入力として与えると未定義な結果となります)。"
1726
1742
1727
1743
#: ../../reference/expressions.rst:1453
1728
1744
msgid "Comparison of sets enforces reflexivity of its elements."
1729
- msgstr ""
1745
+ msgstr "集合の比較では、その要素の反射性が強制されます。 "
1730
1746
1731
1747
#: ../../reference/expressions.rst:1455
1732
1748
msgid ""
1733
1749
"Most other built-in types have no comparison methods implemented, so they "
1734
1750
"inherit the default comparison behavior."
1735
- msgstr ""
1751
+ msgstr "他の組み込み型のほとんどは比較メソッドが実装されておらず、デフォルトの比較の振る舞いを継承します。 "
1736
1752
1737
1753
#: ../../reference/expressions.rst:1458
1738
1754
msgid ""
@@ -1834,6 +1850,8 @@ msgid ""
1834
1850
"Python does not enforce these consistency rules. In fact, the not-a-number "
1835
1851
"values are an example for not following these rules."
1836
1852
msgstr ""
1853
+ "Python はこの一貫性規則を強制しません。\n"
1854
+ "事実、非数値がこの規則に従わない例となります。"
1837
1855
1838
1856
#: ../../reference/expressions.rst:1510
1839
1857
msgid "Membership test operations"
@@ -1895,6 +1913,10 @@ msgid ""
1895
1913
"indices do not raise :exc:`IndexError` exception. (If any other exception "
1896
1914
"is raised, it is as if :keyword:`in` raised that exception)."
1897
1915
msgstr ""
1916
+ "最終的には、旧スタイルの反復プロトコルの実行を試みます: もしクラスが :meth:`__getitem__` を定義しているならば、 ``x in "
1917
+ "y`` は ``x == y[i]`` となるような非負整数のインデックス *i* が存在するとき、かつそのときにかぎり ``True`` "
1918
+ "となります。インデックス *i* が負である場合に :exc:`IndexError` 例外が送出されることはありません。 "
1919
+ "(他の何らかの例外が送出された場合、例外は :keyword:`in` から送出されたかのようになります)。"
1898
1920
1899
1921
#: ../../reference/expressions.rst:1546
1900
1922
msgid ""
@@ -1913,6 +1935,9 @@ msgid ""
1913
1935
"identity is determined using the :meth:`id` function. ``x is not y`` yields"
1914
1936
" the inverse truth value. [#]_"
1915
1937
msgstr ""
1938
+ "演算子 :keyword:`is` および :keyword:`is not` は、オブジェクトの同一性に対するテストを行います: ``x is y`` は、 *x* と *y* が同じオブジェクトを指すとき、かつそのときに限り真になります。\n"
1939
+ "オブジェクトの同一性は :meth:`id` 関数を使って判定されます。\n"
1940
+ "``x is not y`` は :keyword:`is` の真値を反転したものになります。 [#]_"
1916
1941
1917
1942
#: ../../reference/expressions.rst:1573
1918
1943
msgid "Boolean operations"
@@ -1967,6 +1992,9 @@ msgid ""
1967
1992
" argument (for example, ``not 'foo'`` produces ``False`` rather than "
1968
1993
"``''``.)"
1969
1994
msgstr ""
1995
+ "なお、 :keyword:`and` も :keyword:`or` も、返す値を ``True`` や ``False`` に制限せず、最後に評価した引数を返します。\n"
1996
+ "この仕様が便利なときもあります。例えば ``s`` が文字列で、空文字列ならデフォルトの値に置き換えたいとき、式 ``s or 'foo'`` は望んだ値を与えます。\n"
1997
+ ":keyword:`not` は必ず新しい値を作成するので、引数の型に関係なくブール値を返します (例えば、 ``not 'foo'`` は ``''`` ではなく ``False`` になります)。"
1970
1998
1971
1999
#: ../../reference/expressions.rst:1616
1972
2000
msgid "Conditional expressions"
@@ -2002,6 +2030,9 @@ msgid ""
2002
2030
" a function object. The unnamed object behaves like a function object "
2003
2031
"defined with:"
2004
2032
msgstr ""
2033
+ "ラムダ式 (ラムダ形式とも呼ばれます) は無名関数を作成するのに使います。\n"
2034
+ "式 ``lambda parameters: expression`` は関数オブジェクトになります。\n"
2035
+ "この無名オブジェクトは以下に定義されている関数オブジェクト同様に動作します:"
2005
2036
2006
2037
#: ../../reference/expressions.rst:1664
2007
2038
msgid ""
@@ -2022,18 +2053,24 @@ msgid ""
2022
2053
"least one comma yields a tuple. The length of the tuple is the number of "
2023
2054
"expressions in the list. The expressions are evaluated from left to right."
2024
2055
msgstr ""
2056
+ "リスト表示や辞書表示の一部になっているものを除き、少なくとも一つのカンマを含む式のリストはタプルになります。\n"
2057
+ "タプルの長さは、リストにある式の数に等しくなります。\n"
2058
+ "式は左から右へ評価されます。"
2025
2059
2026
2060
#: ../../reference/expressions.rst:1695
2027
2061
msgid ""
2028
2062
"An asterisk ``*`` denotes :dfn:`iterable unpacking`. Its operand must be an"
2029
2063
" :term:`iterable`. The iterable is expanded into a sequence of items, which"
2030
2064
" are included in the new tuple, list, or set, at the site of the unpacking."
2031
2065
msgstr ""
2066
+ "アスタリスク ``*`` は :dfn:`イテラブルのアンパック` を意味します。\n"
2067
+ "この被演算子は :term:`イテラブル <iterable>` でなければなりません。\n"
2068
+ "このイテラブルはアンパックされた位置で要素のシーケンスに展開され、新しいタプル、リスト、集合に入れ込まれます。"
2032
2069
2033
2070
#: ../../reference/expressions.rst:1700
2034
2071
msgid ""
2035
2072
"Iterable unpacking in expression lists, originally proposed by :pep:`448`."
2036
- msgstr ""
2073
+ msgstr "式リストでのイテラブルのアンパックは最初に :pep:`448` で提案されました。 "
2037
2074
2038
2075
#: ../../reference/expressions.rst:1705
2039
2076
msgid ""
@@ -2199,7 +2236,7 @@ msgstr "``*``, ``@``, ``/``, ``//``, ``%``"
2199
2236
msgid ""
2200
2237
"Multiplication, matrix multiplication, division, floor division, remainder "
2201
2238
"[#]_"
2202
- msgstr ""
2239
+ msgstr "乗算、行列乗算、除算、切り捨て除算、剰余 [#]_ "
2203
2240
2204
2241
#: ../../reference/expressions.rst:1783
2205
2242
msgid "``+x``, ``-x``, ``~x``"
@@ -2219,7 +2256,7 @@ msgstr "べき乗 [#]_"
2219
2256
2220
2257
#: ../../reference/expressions.rst:1787
2221
2258
msgid ":keyword:`await` ``x``"
2222
- msgstr ""
2259
+ msgstr ":keyword:`await` ``x`` "
2223
2260
2224
2261
#: ../../reference/expressions.rst:1789
2225
2262
msgid "``x[index]``, ``x[index:index]``, ``x(arguments...)``, ``x.attribute``"
@@ -2300,6 +2337,9 @@ msgid ""
2300
2337
" == \"\\ u0043\\ u0327\" `` is ``False``, even though both strings represent "
2301
2338
"the same abstract character \" LATIN CAPITAL LETTER C WITH CEDILLA\" ."
2302
2339
msgstr ""
2340
+ "文字列の比較操作は Unicode のコードポイントのレベルで行われます。\n"
2341
+ "これは人間にとっては直感的ではないかもしれません。\n"
2342
+ "例えば、 ``\"\\ u00C7\" == \"\\ u0043\\ u0327\" `` は、どちらの文字も同じ抽象文字 \" LATIN CAPITAL LETTER C WITH CEDILLA\" を表現しているにもかかわらず、その結果は ``False`` となります。"
2303
2343
2304
2344
#: ../../reference/expressions.rst:1831
2305
2345
msgid ""
0 commit comments