@@ -8838,15 +8838,15 @@ msgstr ""
8838
8838
8839
8839
#: src/scope/move/mut.md:14
8840
8840
msgid "// *Move* the box, changing the ownership (and mutability)\n"
8841
- msgstr "// *移动* box ,改变所有权(和可变性)\n"
8841
+ msgstr "// *移动*盒子 ,改变所有权(和可变性)\n"
8842
8842
8843
8843
#: src/scope/move/mut.md:17
8844
8844
msgid "\"mutable_box contains {}\""
8845
8845
msgstr "\"mutable_box 包含 {}\""
8846
8846
8847
8847
#: src/scope/move/mut.md:19
8848
8848
msgid "// Modify the contents of the box\n"
8849
- msgstr "// 修改 box 的内容 \n"
8849
+ msgstr "// 修改盒子的内容 \n"
8850
8850
8851
8851
#: src/scope/move/mut.md:22
8852
8852
msgid "\"mutable_box now contains {}\""
@@ -8874,25 +8874,25 @@ msgstr "\"此人的年龄是 {}\""
8874
8874
8875
8875
#: src/scope/move/partial_move.md:29
8876
8876
msgid "\"The person's name is {}\""
8877
- msgstr "\"此人的名字是 {}\""
8877
+ msgstr "\"此人的姓名是 {}\""
8878
8878
8879
8879
#: src/scope/move/partial_move.md:31
8880
8880
msgid ""
8881
8881
"// Error! borrow of partially moved value: `person` partial move occurs\n"
8882
8882
" //println!(\"The person struct is {:?}\", person);\n"
8883
8883
msgstr ""
8884
- "// 错误!借用了部分移动的值 :`person` 发生了部分移动 \n"
8885
- " //println!(\"此人的结构体是 {:?}\", person);\n"
8884
+ "// 错误!借用部分移动的值 :`person` 发生部分移动 \n"
8885
+ " //println!(\"person 结构体是 {:?}\", person);\n"
8886
8886
8887
8887
#: src/scope/move/partial_move.md:34
8888
8888
msgid ""
8889
8889
"// `person` cannot be used but `person.age` can be used as it is not moved\n"
8890
8890
msgstr ""
8891
- "// `person` 不能被使用 ,但 `person.age` 可以使用,因为它没有被移动\n"
8891
+ "// `person` 不能使用 ,但 `person.age` 可以使用,因为它没有被移动\n"
8892
8892
8893
8893
#: src/scope/move/partial_move.md:35
8894
8894
msgid "\"The person's age from person struct is {}\""
8895
- msgstr "\"从 person 结构体中获取的此人年龄是 {}\""
8895
+ msgstr "\"从 person 结构体中获取的年龄是 {}\""
8896
8896
8897
8897
#: src/scope/move/partial_move.md:38
8898
8898
msgid ""
@@ -8922,19 +8922,19 @@ msgid ""
8922
8922
"_always_ point to valid objects. That is, while references to an object "
8923
8923
"exist, the object cannot be destroyed."
8924
8924
msgstr ""
8925
- "编译器通过其借用检查器静态地保证引用**始终**指向有效的对象。也就是说,当存在引用指向一个对象时 ,该对象就不能被销毁。"
8925
+ "编译器通过其借用检查器静态地保证引用**始终**指向有效的对象。也就是说,当存在指向一个对象的引用时 ,该对象就不能被销毁。"
8926
8926
8927
8927
#: src/scope/borrow.md:12
8928
8928
msgid "// This function takes ownership of a box and destroys it\n"
8929
- msgstr "// 这个函数获取一个 box 的所有权并销毁它 \n"
8929
+ msgstr "// 此函数获取一个盒子的所有权并销毁它 \n"
8930
8930
8931
8931
#: src/scope/borrow.md:14
8932
8932
msgid "\"Destroying box that contains {}\""
8933
- msgstr "\"销毁包含 {} 的 box \""
8933
+ msgstr "\"正在销毁包含 {} 的盒子 \""
8934
8934
8935
8935
#: src/scope/borrow.md:16
8936
8936
msgid "// This function borrows an i32\n"
8937
- msgstr "// 这个函数借用一个 i32\n"
8937
+ msgstr "// 此函数借用一个 i32\n"
8938
8938
8939
8939
#: src/scope/borrow.md:19
8940
8940
msgid "\"This int is: {}\""
@@ -8948,20 +8948,20 @@ msgid ""
8948
8948
" // 5_i32 is the same as 5i32\n"
8949
8949
msgstr ""
8950
8950
"// 在堆上创建一个装箱的 i32,在栈上创建一个 i32\n"
8951
- " // 注 :数字可以添加任意下划线以提高可读性\n"
8951
+ " // 注意 :数字可以添加任意下划线以提高可读性\n"
8952
8952
" // 5_i32 与 5i32 相同\n"
8953
8953
8954
8954
#: src/scope/borrow.md:29
8955
8955
msgid ""
8956
8956
"// Borrow the contents of the box. Ownership is not taken,\n"
8957
8957
" // so the contents can be borrowed again.\n"
8958
8958
msgstr ""
8959
- "// 借用 box 的数据 。所有权未被获取,\n"
8959
+ "// 借用盒子的数据 。所有权未被获取,\n"
8960
8960
" // 所以数据可以再次被借用。\n"
8961
8961
8962
8962
#: src/scope/borrow.md:35
8963
8963
msgid "// Take a reference to the data contained inside the box\n"
8964
- msgstr "// 获取 box 内数据的引用 \n"
8964
+ msgstr "// 获取盒子内数据的引用 \n"
8965
8965
8966
8966
#: src/scope/borrow.md:38
8967
8967
msgid ""
@@ -8993,7 +8993,7 @@ msgid ""
8993
8993
"`&T` borrows the data via an immutable reference, and the borrower can read "
8994
8994
"the data but not modify it:"
8995
8995
msgstr ""
8996
- "可变数据可以使用 `&mut T` 进行可变借用。这被称为**可变引用**,并给予借用者读/写访问权 。相比之下,`&T` 通过不可变引用借用数据,借用者可以读取数据但不能修改它:"
8996
+ "可变数据可以使用 `&mut T` 进行可变借用。这被称为**可变引用**,并给予借用者读写访问权 。相比之下,`&T` 通过不可变引用借用数据,借用者可以读取数据但不能修改它:"
8997
8997
8998
8998
#: src/scope/borrow/mut.md:12
8999
8999
msgid ""
@@ -9003,26 +9003,26 @@ msgstr ""
9003
9003
9004
9004
#: src/scope/borrow/mut.md:17
9005
9005
msgid "// This function takes a reference to a book\n"
9006
- msgstr "// 这个函数接受一个对 Book 类型数据的引用 \n"
9006
+ msgstr "// 此函数接受一个对 Book 类型的引用 \n"
9007
9007
9008
9008
#: src/scope/borrow/mut.md:20
9009
9009
msgid "\"I immutably borrowed {} - {} edition\""
9010
- msgstr "\"我不可变地借用了 {} - {} 版\""
9010
+ msgstr "\"我不可变地借用了《{}》 - {} 版\""
9011
9011
9012
9012
#: src/scope/borrow/mut.md:22
9013
9013
msgid ""
9014
9014
"// This function takes a reference to a mutable book and changes `year` to "
9015
9015
"2014\n"
9016
9016
msgstr ""
9017
- "// 这个函数接受一个对可变书的引用 ,并将 `year` 改为 2014\n"
9017
+ "// 此函数接受一个对可变 Book 的引用 ,并将 `year` 改为 2014\n"
9018
9018
9019
9019
#: src/scope/borrow/mut.md:26
9020
9020
msgid "\"I mutably borrowed {} - {} edition\""
9021
- msgstr "\"我可变地借用了 {} - {} 版\""
9021
+ msgstr "\"我可变地借用了《{}》 - {} 版\""
9022
9022
9023
9023
#: src/scope/borrow/mut.md:30
9024
9024
msgid "// Create an immutable Book named `immutabook`\n"
9025
- msgstr "// 创建一个名为 `immutabook` 的不可变 Book\n"
9025
+ msgstr "// 创建一个名为 `immutabook` 的不可变 Book 实例 \n"
9026
9026
9027
9027
#: src/scope/borrow/mut.md:32
9028
9028
msgid "// string literals have type `&'static str`\n"
@@ -9034,11 +9034,11 @@ msgstr "\"Douglas Hofstadter\""
9034
9034
9035
9035
#: src/scope/borrow/mut.md:34
9036
9036
msgid "\"Gödel, Escher, Bach\""
9037
- msgstr "\"Gödel, Escher, Bach \""
9037
+ msgstr "\"哥德尔、埃舍尔、巴赫 \""
9038
9038
9039
9039
#: src/scope/borrow/mut.md:38
9040
9040
msgid "// Create a mutable copy of `immutabook` and call it `mutabook`\n"
9041
- msgstr "// 创建 `immutabook` 的一个可变副本,并将其命名为 `mutabook`\n"
9041
+ msgstr "// 创建 `immutabook` 的可变副本,并命名为 `mutabook`\n"
9042
9042
9043
9043
#: src/scope/borrow/mut.md:41
9044
9044
msgid "// Immutably borrow an immutable object\n"
@@ -9054,7 +9054,7 @@ msgstr "// 可变地借用一个可变对象\n"
9054
9054
9055
9055
#: src/scope/borrow/mut.md:50
9056
9056
msgid "// Error! Cannot borrow an immutable object as mutable\n"
9057
- msgstr "// 错误!不能可变地借用一个不可变对象 \n"
9057
+ msgstr "// 错误!不能将不可变对象作为可变对象借用 \n"
9058
9058
9059
9059
#: src/scope/borrow/mut.md:57
9060
9060
msgid "[`static`](../lifetime/static_lifetime.md)"
@@ -9068,7 +9068,7 @@ msgid ""
9068
9068
"borrowed again only _after_ the mutable reference has been used for the last "
9069
9069
"time."
9070
9070
msgstr ""
9071
- "数据可以被不可变地借用任意次数 ,但在不可变借用期间,原始数据不能被可变地借用 。另一方面,同一时间只允许**一个**可变借用。只有在可变引用最后一次使用之后,原始数据才能再次被借用。"
9071
+ "数据可以被不可变借用任意次数 ,但在不可变借用期间,原始数据不能被可变借用 。另一方面,同一时间只允许**一个**可变借用。只有在可变引用最后一次使用之后,原始数据才能再次被借用。"
9072
9072
9073
9073
#: src/scope/borrow/alias.md:17
9074
9074
msgid "// Data can be accessed via the references and the original owner\n"
@@ -9077,7 +9077,7 @@ msgstr "// 可以通过引用和原始所有者访问数据\n"
9077
9077
#: src/scope/borrow/alias.md:18 src/scope/borrow/alias.md:27
9078
9078
#: src/scope/borrow/alias.md:49
9079
9079
msgid "\"Point has coordinates: ({}, {}, {})\""
9080
- msgstr "\"Point has coordinates: ({}, {}, {})\""
9080
+ msgstr "\"点的坐标为: ({}, {}, {})\""
9081
9081
9082
9082
#: src/scope/borrow/alias.md:21
9083
9083
msgid ""
@@ -9100,11 +9100,11 @@ msgid ""
9100
9100
" // it is possible to reborrow with a mutable reference.\n"
9101
9101
msgstr ""
9102
9102
"// 不可变引用在代码的剩余部分不再使用\n"
9103
- " // 所以可以用可变引用重新借用 。\n"
9103
+ " // 因此可以用可变引用重新借用 。\n"
9104
9104
9105
9105
#: src/scope/borrow/alias.md:34
9106
9106
msgid "// Change data via mutable reference\n"
9107
- msgstr "// 通过可变引用改变数据 \n"
9107
+ msgstr "// 通过可变引用修改数据 \n"
9108
9108
9109
9109
#: src/scope/borrow/alias.md:39
9110
9110
msgid ""
@@ -9123,13 +9123,13 @@ msgid ""
9123
9123
" // println!(\"Point Z coordinate is {}\", point.z);\n"
9124
9124
" // TODO ^ Try uncommenting this line\n"
9125
9125
msgstr ""
9126
- "// 错误!不能打印 ,因为 `println!` 用到了一个不可变引用 。\n"
9127
- " // println!(\"Point Z coordinate is {}\", point.z);\n"
9126
+ "// 错误!无法打印 ,因为 `println!` 需要一个不可变引用 。\n"
9127
+ " // println!(\"点的 Z 坐标是 {}\", point.z);\n"
9128
9128
" // TODO ^ 尝试取消注释此行\n"
9129
9129
9130
9130
#: src/scope/borrow/alias.md:48
9131
9131
msgid "// Ok! Mutable references can be passed as immutable to `println!`\n"
9132
- msgstr "// 可以 !可变引用可以作为不可变引用传递给 `println!`\n"
9132
+ msgstr "// 正确 !可变引用可以作为不可变引用传递给 `println!`\n"
9133
9133
9134
9134
#: src/scope/borrow/alias.md:52
9135
9135
msgid ""
@@ -9140,15 +9140,15 @@ msgstr ""
9140
9140
9141
9141
#: src/scope/borrow/alias.md:55
9142
9142
msgid "\"Point now has coordinates: ({}, {}, {})\""
9143
- msgstr "\"Point now has coordinates: ({}, {}, {})\""
9143
+ msgstr "\"点现在的坐标为: ({}, {}, {})\""
9144
9144
9145
9145
#: src/scope/borrow/ref.md:3
9146
9146
msgid ""
9147
9147
"When doing pattern matching or destructuring via the `let` binding, the `ref` "
9148
9148
"keyword can be used to take references to the fields of a struct/tuple. The "
9149
9149
"example below shows a few instances where this can be useful:"
9150
9150
msgstr ""
9151
- "在通过 `let` 绑定进行模式匹配或解构时,可以使用 `ref` 关键字来获取结构体/元组字段的引用。下面的例子展示了几个这种用法有用的情况 :"
9151
+ "在使用 `let` 绑定进行模式匹配或解构时,可以使用 `ref` 关键字来获取结构体或元组字段的引用。以下示例展示了几个这种用法有用的场景 :"
9152
9152
9153
9153
#: src/scope/borrow/ref.md:14
9154
9154
msgid ""
@@ -9159,7 +9159,7 @@ msgstr ""
9159
9159
9160
9160
#: src/scope/borrow/ref.md:19
9161
9161
msgid "\"ref_c1 equals ref_c2: {}\""
9162
- msgstr "\"ref_c1 equals ref_c2: {}\""
9162
+ msgstr "\"ref_c1 等于 ref_c2: {}\""
9163
9163
9164
9164
#: src/scope/borrow/ref.md:23
9165
9165
msgid "// `ref` is also valid when destructuring a struct.\n"
@@ -9171,39 +9171,39 @@ msgstr "// `ref_to_x` 是 `point` 的 `x` 字段的引用。\n"
9171
9171
9172
9172
#: src/scope/borrow/ref.md:28
9173
9173
msgid "// Return a copy of the `x` field of `point`.\n"
9174
- msgstr "// 返回 `point` 的 `x` 字段的拷贝 。\n"
9174
+ msgstr "// 返回 `point` 的 `x` 字段的副本 。\n"
9175
9175
9176
9176
#: src/scope/borrow/ref.md:32
9177
9177
msgid "// A mutable copy of `point`\n"
9178
- msgstr "// `point` 的可变拷贝 \n"
9178
+ msgstr "// `point` 的可变副本 \n"
9179
9179
9180
9180
#: src/scope/borrow/ref.md:36
9181
9181
msgid "// `ref` can be paired with `mut` to take mutable references.\n"
9182
- msgstr "// `ref` 可以与 `mut` 配对来获取可变引用 。\n"
9182
+ msgstr "// `ref` 可以与 `mut` 配合使用来获取可变引用 。\n"
9183
9183
9184
9184
#: src/scope/borrow/ref.md:39
9185
9185
msgid "// Mutate the `y` field of `mutable_point` via a mutable reference.\n"
9186
9186
msgstr "// 通过可变引用修改 `mutable_point` 的 `y` 字段。\n"
9187
9187
9188
9188
#: src/scope/borrow/ref.md:43
9189
9189
msgid "\"point is ({}, {})\""
9190
- msgstr "\"point is ({}, {})\""
9190
+ msgstr "\"point 的坐标是 ({}, {})\""
9191
9191
9192
9192
#: src/scope/borrow/ref.md:44
9193
9193
msgid "\"mutable_point is ({}, {})\""
9194
- msgstr "\"mutable_point is ({}, {})\""
9194
+ msgstr "\"mutable_point 的坐标是 ({}, {})\""
9195
9195
9196
9196
#: src/scope/borrow/ref.md:46
9197
9197
msgid "// A mutable tuple that includes a pointer\n"
9198
9198
msgstr "// 包含指针的可变元组\n"
9199
9199
9200
9200
#: src/scope/borrow/ref.md:50
9201
9201
msgid "// Destructure `mutable_tuple` to change the value of `last`.\n"
9202
- msgstr "// 解构 `mutable_tuple` 以改变 `last` 的值。\n"
9202
+ msgstr "// 解构 `mutable_tuple` 以修改 `last` 的值。\n"
9203
9203
9204
9204
#: src/scope/borrow/ref.md:55
9205
9205
msgid "\"tuple is {:?}\""
9206
- msgstr "\"tuple is {:?}\""
9206
+ msgstr "\"元组是 {:?}\""
9207
9207
9208
9208
#: src/scope/lifetime.md:3
9209
9209
msgid ""
@@ -9212,7 +9212,7 @@ msgid ""
9212
9212
"lifetime begins when it is created and ends when it is destroyed. While "
9213
9213
"lifetimes and scopes are often referred to together, they are not the same."
9214
9214
msgstr ""
9215
- "**生命周期**是编译器(更具体地说是其**借用检查器**)用来确保所有借用都是有效的一个构造 。具体来说,变量的生命周期从创建时开始,到销毁时结束。虽然生命周期和作用域经常被一起提到,但它们并不相同。"
9215
+ "**生命周期**是编译器(更具体地说是其**借用检查器**)用来确保所有借用都有效的一种机制 。具体来说,变量的生命周期从创建时开始,到销毁时结束。虽然生命周期和作用域经常被一起提到,但它们并不相同。"
9216
9216
9217
9217
#: src/scope/lifetime.md:8
9218
9218
msgid ""
0 commit comments