From fab5974fcde5f49b872b5a0cc4fc891de8e9086b Mon Sep 17 00:00:00 2001 From: andywang Date: Sat, 7 Nov 2026 12:36:41 +0800 Subject: [PATCH] Working on c-api/hash.po --- c-api/hash.po | 35 +++++++++++++++++++++++++++-------- 1 file changed, 27 insertions(+), 8 deletions(-) diff --git a/c-api/hash.po b/c-api/hash.po index 7ec708bf846..07cc3d316b7 100644 --- a/c-api/hash.po +++ b/c-api/hash.po @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: Python 3.14\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2025-11-09 00:17+0000\n" -"PO-Revision-Date: 2024-04-30 00:20+0800\n" +"PO-Revision-Date: 2026-11-07 12:31+0800\n" "Last-Translator: Matt Wang \n" "Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-" "tw)\n" @@ -16,6 +16,7 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" +"X-Generator: Poedit 3.10\n" #: ../../c-api/hash.rst:4 msgid "PyHash API" @@ -36,9 +37,11 @@ msgstr "雜湊值型別:無符號整數。" #: ../../c-api/hash.rst:24 msgid "" -"A numerical value indicating the algorithm for hashing of :class:`str`, :" -"class:`bytes`, and :class:`memoryview`." +"A numerical value indicating the algorithm for hashing " +"of :class:`str`, :class:`bytes`, and :class:`memoryview`." msgstr "" +"用一個數值,表示用於對 :class:`str`、:class:`bytes` 和 :class:`memoryview` 進" +"行雜湊的演算法。" #: ../../c-api/hash.rst:27 msgid "The algorithm name is exposed by :data:`sys.hash_info.algorithm`." @@ -50,6 +53,9 @@ msgid "" "which algorithm is used for hashing. The hash algorithm can be configured " "via the configure :option:`--with-hash-algorithm` option." msgstr "" +"用來與 :c:macro:`Py_HASH_ALGORITHM` 比較的數值,以判斷使用哪一種雜湊演算" +"法。\n" +"雜湊演算法可透過 configure 的 :option:`--with-hash-algorithm` 選項設定。" #: ../../c-api/hash.rst:40 msgid "Add :c:macro:`!Py_HASH_FNV` and :c:macro:`!Py_HASH_SIPHASH24`." @@ -64,6 +70,8 @@ msgid "" "Buffers of length in range ``[1, Py_HASH_CUTOFF)`` are hashed using DJBX33A " "instead of the algorithm described by :c:macro:`Py_HASH_ALGORITHM`." msgstr "" +"長度在 ``[1, Py_HASH_CUTOFF)`` 範圍內的緩衝區,會使用 DJBX33A 進行雜湊,\n" +"而非 :c:macro:`Py_HASH_ALGORITHM` 所指定的演算法。" #: ../../c-api/hash.rst:52 msgid "A :c:macro:`!Py_HASH_CUTOFF` of 0 disables the optimization." @@ -80,6 +88,10 @@ msgid "" "it is easier to create colliding strings. A cutoff of 7 on 64-bit platforms " "and 5 on 32-bit platforms should provide a decent safety margin." msgstr "" +"32 位元的平台應使用比 64 位元的平台更小的門檻值,因為在 32 位元平台上更容易建" +"立會發生雜湊碰撞的字串。\n" +"若在 64 位元平台上將門檻值設為 7,在 32 位元平台上設為 5,應能提供適當的安全" +"餘裕。" #: ../../c-api/hash.rst:59 msgid "This corresponds to the :data:`sys.hash_info.cutoff` constant." @@ -178,16 +190,23 @@ msgstr "此函式不會失敗:它不會回傳 ``-1``。" #: ../../c-api/hash.rst:157 msgid "" "Compute and return the hash value of a buffer of *len* bytes starting at " -"address *ptr*. The hash is guaranteed to match that of :class:`bytes`, :" -"class:`memoryview`, and other built-in objects that implement the :ref:" -"`buffer protocol `." +"address *ptr*. The hash is guaranteed to match that " +"of :class:`bytes`, :class:`memoryview`, and other built-in objects that " +"implement the :ref:`buffer protocol `." msgstr "" +"計算並回傳從位址 *ptr* 開始、長度為 *len* 位元組的緩衝區之雜湊值。\n" +"此雜湊值會保證與 :class:`bytes`、:class:`memoryview` 及其他實作\n" +":ref:`緩衝協定 ` 的內建物件之雜湊值一致。" #: ../../c-api/hash.rst:162 msgid "" -"Use this function to implement hashing for immutable objects whose :c:member:" -"`~PyTypeObject.tp_richcompare` function compares to another object's buffer." +"Use this function to implement hashing for immutable objects " +"whose :c:member:`~PyTypeObject.tp_richcompare` function compares to another " +"object's buffer." msgstr "" +"使用此函式,對透過 :c:member:~PyTypeObject.tp_richcompare 函式與另一個物件的" +"緩衝區\n" +"進行比較的不可變物件其雜湊功能." #: ../../c-api/hash.rst:166 msgid "*len* must be greater than or equal to ``0``."