mirror of
https://github.com/google/comprehensive-rust.git
synced 2024-12-14 14:10:05 +02:00
zh-TW: fix line breaks in lists (#1036)
* zh-TW: fix line breaks in lists I looked through the recent PRs for the Taiwanese translations and found that some lists items had extra line breaks (without the necessary indentation). This PR should fix the rendering. Part of #684. * Apply suggestions from code review --------- Co-authored-by: Jonathan Hao <phao@google.com>
This commit is contained in:
parent
e1ef954d08
commit
e364e020cb
30
po/zh-TW.po
30
po/zh-TW.po
@ -9028,15 +9028,13 @@ msgid ""
|
||||
" you can iterate over a vector with `for i in some_vec { .. }` but\n"
|
||||
" `some_vec.next()` doesn't exist."
|
||||
msgstr ""
|
||||
"*`Iterator` 特徵會對集合實作許多常見的函式程式操作,\n"
|
||||
"例如 `map`、`filter`、`reduce` 等等。您可以藉由此特徵找出\n"
|
||||
"所有相關的說明文件。在 Rust 中,這些函式會產生程式碼,且應與對應的命令式\n"
|
||||
"實作項目一樣有效率。\n"
|
||||
"* `Iterator` 特徵會對集合實作許多常見的函式程式操作,例如 `map`、`filter`、"
|
||||
" `reduce` 等等。您可以藉由此特徵找出所有相關的說明文件。在 Rust 中,這些"
|
||||
" 函式會產生程式碼,且應與對應的命令式實作項目一樣有效率。\n"
|
||||
" \n"
|
||||
"*`IntoIterator` 是迫使 for 迴圈運作的特徵。此特徵由集合型別\n"
|
||||
"(例如 `Vec<T>`) 和相關參照 (`&Vec<T>` 與 `&[T]`) 實作而成。此外,範圍也會實作"
|
||||
"這項特徵。這就說明了\n"
|
||||
"您為何可以透過 `for i in some_vec { .. }` 對向量進行疊代,即使沒有 \n"
|
||||
"* `IntoIterator` 是迫使 for 迴圈運作的特徵。此特徵由集合型別(例如 `Vec<T>`) "
|
||||
" 和相關參照 (`&Vec<T>` 與 `&[T]`) 實作而成。此外,範圍也會實作這項特徵。"
|
||||
" 這就說明了您為何可以透過 `for i in some_vec { .. }` 對向量進行疊代,即使沒有 "
|
||||
"`some_vec.next()` 也無妨。"
|
||||
|
||||
#: src/traits/from-iterator.md:1
|
||||
@ -9369,16 +9367,14 @@ msgid ""
|
||||
" `impl Add<(i32, i32)> for Point` would add a tuple to a `Point`."
|
||||
msgstr ""
|
||||
"* 您可以針對 `&Point` 實作 `Add`。但這能在哪些情況派上用場?\n"
|
||||
" * 回答:`Add:add` 會耗用 `self`。如果您要\n"
|
||||
"超載運算子的型別 `T` 不是 `Copy`,建議您一併為 `&T`\n"
|
||||
"超載運算子。這可避免呼叫\n"
|
||||
"點中出現不必要的複製作業。\n"
|
||||
" * 回答:`Add:add` 會耗用 `self`。如果您要超載運算子的型別 `T` 不是 "
|
||||
" `Copy`,建議您一併為 `&T` 超載運算子。這可避免呼叫點中出現不必要"
|
||||
" 的複製作業。\n"
|
||||
"* 為什麼 `Output` 是關聯型別?可將其用做方法的型別參數嗎?\n"
|
||||
" * 簡答:函式型別參數是由呼叫端控管,但\n"
|
||||
"`Output` 這類關聯型別則由\n"
|
||||
"特徵實作者控管。\n"
|
||||
"* 您可以針對兩種不同型別實作 `Add`,\n"
|
||||
"舉例來說,`impl Add<(i32, i32)> for Point` 會將元組新增至 `Point`。"
|
||||
" * 簡答:函式型別參數是由呼叫端控管,但 `Output` 這類關聯型別則由特徵"
|
||||
" 實作者控管。\n"
|
||||
"* 您可以針對兩種不同型別實作 `Add`,舉例來說,"
|
||||
" `impl Add<(i32, i32)> for Point` 會將元組新增至 `Point`。"
|
||||
|
||||
#: src/traits/closures.md:1
|
||||
msgid "# Closures"
|
||||
|
Loading…
Reference in New Issue
Block a user