Also, I've corrected src/doc/README.md in line with this change.
Signed-off-by: OGINO Masanori <masanori.ogino@gmail.com>
--package-name="Rust" \
--package-version="0.10-pre" \
-M UTF-8 -L UTF-8 \
- po4a.conf
+ src/doc/po4a.conf
~~~~
(the version number must be changed if it is not 0.10-pre now.)
change:
~~~~
-for f in doc/po/**/*.po; do
+for f in src/doc/po/**/*.po; do
msgattrib --translated $f -o $f.strip
if [ -e $f.strip ]; then
mv $f.strip $f
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/complement-cheatsheet.md:13
+#: src/doc/complement-cheatsheet.md:8
+#, fuzzy
+#| msgid ""
+#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
+#| "http://static.rust-lang.org/dist/rust-0.7-install.exe"
+msgid ""
+"Use [`ToStr`](http://static.rust-lang.org/doc/master/std/to_str/trait.ToStr."
+"html)."
+msgstr ""
+"[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz\n"
+"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:13
#, fuzzy
#| msgid ""
#| "~~~~ let x: f64 = 4.0; let y: uint = x as uint; assert!(y == 4u); ~~~~"
"~~~~"
#. type: Plain text
-#: doc/complement-cheatsheet.md:17
+#: src/doc/complement-cheatsheet.md:17
#, fuzzy
#| msgid ""
#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
#. type: Plain text
-#: doc/complement-cheatsheet.md:22
+#: src/doc/complement-cheatsheet.md:22
#, fuzzy
#| msgid ""
#| "~~~~ let x: f64 = 4.0; let y: uint = x as uint; assert!(y == 4u); ~~~~"
"~~~~"
#. type: Plain text
-#: doc/complement-cheatsheet.md:29
+#: src/doc/complement-cheatsheet.md:26
+#, fuzzy
+#| msgid ""
+#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
+#| "http://static.rust-lang.org/dist/rust-0.7-install.exe"
+msgid ""
+"Use [`ToStrRadix`](http://static.rust-lang.org/doc/master/std/num/trait."
+"ToStrRadix.html)."
+msgstr ""
+"[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz\n"
+"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:29
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~ use std::num::ToStrRadix;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/complement-cheatsheet.md:33
+#: src/doc/complement-cheatsheet.md:33
#, fuzzy
#| msgid ""
#| "~~~~ let x: f64 = 4.0; let y: uint = x as uint; assert!(y == 4u); ~~~~"
"~~~~"
#. type: Plain text
-#: doc/complement-cheatsheet.md:37
+#: src/doc/complement-cheatsheet.md:37
#, fuzzy
#| msgid ""
#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
#. type: Plain text
-#: doc/complement-cheatsheet.md:40
+#: src/doc/complement-cheatsheet.md:40
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~ use std::num::from_str_radix;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/complement-cheatsheet.md:46
+#: src/doc/complement-cheatsheet.md:44
+#, fuzzy
+#| msgid ""
+#| "~~~~ let x: f64 = 4.0; let y: uint = x as uint; assert!(y == 4u); ~~~~"
+msgid ""
+"let x: Option<i64> = from_str_radix(\"deadbeef\", 16); let y: i64 = x."
+"unwrap(); ~~~"
+msgstr ""
+"~~~~\n"
+"let x: f64 = 4.0;\n"
+"let y: uint = x as uint;\n"
+"assert!(y == 4u);\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:46
#, fuzzy
#| msgid "## Operators"
msgid "# File operations"
msgstr "## 演算子"
#. type: Plain text
-#: doc/complement-cheatsheet.md:54
+#: src/doc/complement-cheatsheet.md:50
+#, fuzzy
+#| msgid ""
+#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
+#| "http://static.rust-lang.org/dist/rust-0.7-install.exe"
+msgid ""
+"Use [`File::open`](http://static.rust-lang.org/doc/master/std/io/fs/struct."
+"File.html#method.open) to create a [`File`](http://static.rust-lang.org/doc/"
+"master/std/io/fs/struct.File.html) struct, which implements the [`Reader`]"
+"(http://static.rust-lang.org/doc/master/std/io/trait.Reader.html) trait."
+msgstr ""
+"[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz\n"
+"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:54
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~ {.ignore} use std::path::Path; use std::io::fs::File;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/complement-cheatsheet.md:63
+#: src/doc/complement-cheatsheet.md:63
#, fuzzy
#| msgid ""
#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
#. type: Plain text
-#: doc/complement-cheatsheet.md:77
+#: src/doc/complement-cheatsheet.md:67
+#, fuzzy
+#| msgid "~~~~ use std::task::spawn;"
+msgid "~~~ use std::io::BufferedReader; # use std::io::MemReader;"
+msgstr ""
+"~~~~\n"
+"use std::task::spawn;"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:77
#, fuzzy
#| msgid "## Using other crates"
msgid "# String operations"
msgstr "## 他のクレートの利用"
#. type: Plain text
-#: doc/complement-cheatsheet.md:88 doc/guide-container.md:4
+#: src/doc/complement-cheatsheet.md:81
+#, fuzzy
+#| msgid ""
+#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
+#| "http://static.rust-lang.org/dist/rust-0.7-install.exe"
+msgid ""
+"Use the [`find_str`](http://static.rust-lang.org/doc/master/std/str/trait."
+"StrSlice.html#tymethod.find_str) method."
+msgstr ""
+"[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz\n"
+"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:88 src/doc/guide-container.md:4
#, fuzzy
msgid "# Containers"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/complement-cheatsheet.md:176
+#: src/doc/complement-cheatsheet.md:92
+#, fuzzy
+#| msgid ""
+#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
+#| "http://static.rust-lang.org/dist/rust-0.7-install.exe"
+msgid ""
+"The [`Container`](http://static.rust-lang.org/doc/master/std/container/trait."
+"Container.html) trait provides the `len` method."
+msgstr ""
+"[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz\n"
+"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:104
+#, fuzzy
+#| msgid ""
+#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
+#| "http://static.rust-lang.org/dist/rust-0.7-install.exe"
+msgid ""
+"Use the [`iter`](http://static.rust-lang.org/doc/master/std/vec/trait."
+"ImmutableVector.html#tymethod.iter) method."
+msgstr ""
+"[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz\n"
+"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:113
+#, fuzzy
+#| msgid ""
+#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
+#| "http://static.rust-lang.org/dist/rust-0.7-install.exe"
+msgid ""
+"(See also [`mut_iter`](http://static.rust-lang.org/doc/master/std/vec/trait."
+"MutableVector.html#tymethod.mut_iter) which yields `&mut int` and "
+"[`move_iter`](http://static.rust-lang.org/doc/master/std/vec/trait."
+"OwnedVector.html#tymethod.move_iter) which yields `int` while consuming the "
+"`values` vector.)"
+msgstr ""
+"[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz\n"
+"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:115 src/doc/rust.md:3019
+#, fuzzy
+msgid "# Type system"
+msgstr "## タプル"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:122
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~\n"
+"struct Foo {\n"
+" myfunc: fn(int, uint) -> i32\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:130
+#, fuzzy, no-wrap
+#| msgid "~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+msgid ""
+"fn a(a: int, b: uint) -> i32 {\n"
+" (a as uint + b) as i32\n"
+"}\n"
+msgstr ""
+"~~~~\n"
+"fn line(a: int, b: int, x: int) -> int { a * x + b }\n"
+"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:138
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"fn main() {\n"
+" let f = Foo { myfunc: a };\n"
+" let g = FooClosure { myfunc: |a, b| { (a - b as int) as i32 } };\n"
+" println!(\"{}\", (f.myfunc)(1, 2));\n"
+" println!(\"{}\", (g.myfunc)(3, 4));\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:176
#, fuzzy
#| msgid "[The foreign function interface][ffi]"
msgid "# FFI (Foreign Function Interface)"
msgstr "[他言語間インターフェース (foreign function inferface)][ffi]"
+
+#. type: Plain text
+#: src/doc/complement-cheatsheet.md:178
+#, fuzzy
+#| msgid "# Control structures"
+msgid "## C function signature conversions"
+msgstr "# 制御構造"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/complement-lang-faq.md:83
+#: src/doc/complement-lang-faq.md:2
+#, fuzzy
+#| msgid "## Structs"
+msgid "% Language FAQ"
+msgstr "## 構造体"
+
+#. type: Plain text
+#: src/doc/complement-lang-faq.md:4
+#, fuzzy
+#| msgid "## Structs"
+msgid "# General language issues"
+msgstr "## 構造体"
+
+#. type: Plain text
+#: src/doc/complement-lang-faq.md:83
#, fuzzy
#| msgid ""
#| "[bug-3319]: https://github.com/mozilla/rust/issues/3319 [wiki-start]: "
"developing-Rust"
#. type: Plain text
-#: doc/complement-lang-faq.md:110
+#: src/doc/complement-lang-faq.md:99
+#, fuzzy
+#| msgid ""
+#| "[bug-3319]: https://github.com/mozilla/rust/issues/3319 [wiki-start]: "
+#| "https://github.com/mozilla/rust/wiki/Note-getting-started-developing-Rust"
+msgid ""
+"[sprocketnes]: https://github.com/pcwalton/sprocketnes [hash]: https://"
+"github.com/mozilla/rust/blob/master/src/libstd/hash.rs [HashMap]: https://"
+"github.com/mozilla/rust/blob/master/src/libstd/hashmap.rs [json]: https://"
+"github.com/mozilla/rust/blob/master/src/libextra/json.rs"
+msgstr ""
+"[bug-3319]: https://github.com/mozilla/rust/issues/3319\n"
+"[wiki-start]: https://github.com/mozilla/rust/wiki/Note-getting-started-"
+"developing-Rust"
+
+#. type: Plain text
+#: src/doc/complement-lang-faq.md:110
#, fuzzy
#| msgid ""
#| "[bug-3319]: https://github.com/mozilla/rust/issues/3319 [wiki-start]: "
"[bug-3319]: https://github.com/mozilla/rust/issues/3319\n"
"[wiki-start]: https://github.com/mozilla/rust/wiki/Note-getting-started-"
"developing-Rust"
+
+#. type: Plain text
+#: src/doc/complement-lang-faq.md:131
+#, fuzzy
+#| msgid "## Structs"
+msgid "# Specific language issues"
+msgstr "## 構造体"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Bullet: '* '
-#: doc/complement-project-faq.md:36
+#: src/doc/complement-project-faq.md:36
#, fuzzy
#| msgid "## The standard library"
msgid "An evolving standard library."
--- /dev/null
+# Japanese translations for Rust package
+# Copyright (C) 2014 The Rust Project Developers
+# This file is distributed under the same license as the Rust package.
+# Automatically generated, 2014.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Rust 0.10-pre\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
+"PO-Revision-Date: 2014-02-03 08:13+0900\n"
+"Last-Translator: Automatically generated\n"
+"Language-Team: none\n"
+"Language: ja\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+
+#. type: Plain text
+#: src/doc/complement-usage-faq.md:2
+#, fuzzy
+#| msgid "## Structs"
+msgid "% Usage FAQ"
+msgstr "## 構造体"
+
+#. type: Plain text
+#: src/doc/complement-usage-faq.md:18
+#, fuzzy
+#| msgid ""
+#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
+#| "http://static.rust-lang.org/dist/rust-0.7-install.exe"
+msgid "[1]:http://doc.rust-lang.org/doc/master/rust.html#logging-system"
+msgstr ""
+"[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz\n"
+"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/guide-conditions.md:2
+#: src/doc/guide-conditions.md:2
#, fuzzy
#| msgid "% The Rust Language Tutorial"
msgid "% The Rust Condition and Error-handling Guide"
msgstr "% Rust 言語チュートリアル"
#. type: Plain text
-#: doc/guide-conditions.md:4 doc/guide-ffi.md:4 doc/guide-lifetimes.md:4
-#: doc/guide-macros.md:4 doc/guide-rustpkg.md:4 doc/guide-tasks.md:4
-#: doc/rust.md:4 doc/rustpkg.md:4 doc/tutorial.md:4
+#: src/doc/guide-conditions.md:4 src/doc/guide-ffi.md:4
+#: src/doc/guide-lifetimes.md:4 src/doc/guide-macros.md:4
+#: src/doc/guide-tasks.md:4 src/doc/rust.md:4 src/doc/tutorial.md:4
msgid "# Introduction"
msgstr "# イントロダクション"
#. type: Bullet: ' - '
-#: doc/guide-conditions.md:14
+#: src/doc/guide-conditions.md:14
#, fuzzy
#| msgid "# Functions"
msgid "Options"
msgstr "# 関数"
#. type: Bullet: ' - '
-#: doc/guide-conditions.md:14
+#: src/doc/guide-conditions.md:14
#, fuzzy
#| msgid "## Conditionals"
msgid "Conditions"
msgstr "## 条件式"
#. type: Plain text
-#: doc/guide-conditions.md:19
+#: src/doc/guide-conditions.md:19
#, fuzzy
#| msgid "## Tuples"
msgid "# Example program"
msgstr "## タプル"
#. type: Plain text
-#: doc/guide-conditions.md:112
+#: src/doc/guide-conditions.md:69 src/doc/guide-conditions.md:374
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"fn main() {\n"
+" let pairs = read_int_pairs();\n"
+" for &(a,b) in pairs.iter() {\n"
+" println!(\"{:4.4d}, {:4.4d}\", a, b);\n"
+" }\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-conditions.md:110
#, fuzzy
#| msgid "# Functions"
msgid "# Options"
msgstr "# 関数"
#. type: Plain text
-#: doc/guide-conditions.md:318
+#: src/doc/guide-conditions.md:262
+#, fuzzy
+#| msgid ""
+#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello "
+#| "\" + world::explore()); } ~~~~"
+msgid "fn main() {"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-conditions.md:271 src/doc/guide-conditions.md:519
+#: src/doc/guide-conditions.md:612
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+" // The protected logic.\n"
+" let pairs = read_int_pairs();\n"
+" for &(a,b) in pairs.iter() {\n"
+" println!(\"{:4.4d}, {:4.4d}\", a, b);\n"
+" }\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-conditions.md:314
#, fuzzy
#| msgid "## Conditionals"
msgid "# Conditions"
msgstr "## 条件式"
#. type: Plain text
-#: doc/guide-conditions.md:415
+#: src/doc/guide-conditions.md:409
#, fuzzy
#| msgid "## Traits"
msgid "# Trapping a condition"
msgstr "## トレイト"
+
+#. type: Plain text
+#: src/doc/guide-conditions.md:444
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+" // The protected logic.\n"
+" let pairs = read_int_pairs();\n"
+" for &(a,b) in pairs.iter() {\n"
+" println!(\"{:4.4d}, {:4.4d}\", a, b);\n"
+" }\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-conditions.md:480
+#, fuzzy
+#| msgid "## Traits"
+msgid "# Refining a condition"
+msgstr "## トレイト"
+
+#. type: Plain text
+#: src/doc/guide-conditions.md:566
+#, fuzzy
+#| msgid "## Traits"
+msgid "# Further refining a condition"
+msgstr "## トレイト"
+
+#. type: Plain text
+#: src/doc/guide-conditions.md:739
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+" // The protected logic.\n"
+" let pairs = read_int_pairs();\n"
+" for &(a,b) in pairs.iter() {\n"
+" println!(\"{:4.4d}, {:4.4d}\", a, b);\n"
+" }\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/complement-cheatsheet.md:88 doc/guide-container.md:4
+#: src/doc/complement-cheatsheet.md:88 src/doc/guide-container.md:4
#, fuzzy
msgid "# Containers"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/guide-container.md:2
+#: src/doc/guide-container.md:2
#, fuzzy
#| msgid "% The Rust Language Tutorial"
msgid "% The Rust Containers and Iterators Guide"
msgstr "% Rust 言語チュートリアル"
#. type: Plain text
-#: doc/guide-container.md:8
+#: src/doc/guide-container.md:8
#, fuzzy
#| msgid "# Control structures"
msgid "## Unique vectors"
msgstr "# 制御構造"
#. type: Plain text
-#: doc/guide-container.md:18
+#: src/doc/guide-container.md:18
#, fuzzy
#| msgid "## Managed closures"
msgid "## Maps and sets"
msgstr "## マネージドクロージャ"
#. type: Plain text
-#: doc/guide-container.md:24
+#: src/doc/guide-container.md:24
#, fuzzy
#| msgid "## The standard library"
msgid "The standard library provides three owned map/set types:"
msgstr "## 標準ライブラリ"
#. type: Plain text
-#: doc/guide-container.md:68
+#: src/doc/guide-container.md:44
+#, fuzzy
+#| msgid "# Control structures"
+msgid "## Double-ended queues"
+msgstr "# 制御構造"
+
+#. type: Plain text
+#: src/doc/guide-container.md:68
#, fuzzy
#| msgid "## Operators"
msgid "# Iterators"
msgstr "## 演算子"
#. type: Plain text
-#: doc/guide-container.md:70
+#: src/doc/guide-container.md:70
#, fuzzy
#| msgid "# Introduction"
msgid "## Iteration protocol"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/guide-container.md:119
+#: src/doc/guide-container.md:85
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"impl Iterator<int> for ZeroStream {\n"
+" fn next(&mut self) -> Option<int> {\n"
+" Some(0)\n"
+" }\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-container.md:119
#, fuzzy
#| msgid "# Control structures"
msgid "## Container iterators"
msgstr "# 制御構造"
#. type: Plain text
-#: doc/guide-container.md:131
+#: src/doc/guide-container.md:131
#, fuzzy
#| msgid "## Freezing"
msgid "### Freezing"
msgstr "## 凍結"
#. type: Plain text
-#: doc/guide-container.md:151
+#: src/doc/guide-container.md:151
#, fuzzy
#| msgid "## Operators"
msgid "## Iterator adaptors"
msgstr "## 演算子"
#. type: Plain text
-#: doc/guide-container.md:201
+#: src/doc/guide-container.md:201
#, fuzzy
#| msgid "## Loops"
msgid "## For loops"
msgstr "## ループ"
#. type: Plain text
-#: doc/guide-container.md:257
+#: src/doc/guide-container.md:257
#, fuzzy
#| msgid "## Conventions"
msgid "## Conversion"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/guide-container.md:334
+#: src/doc/guide-container.md:287
+#, fuzzy
+#| msgid "## Structs"
+msgid "### Size hints"
+msgstr "## 構造体"
+
+#. type: Plain text
+#: src/doc/guide-container.md:334
#, fuzzy
#| msgid "# Control structures"
msgid "## Double-ended iterators"
msgstr "# 制御構造"
#. type: Plain text
-#: doc/guide-container.md:385
+#: src/doc/guide-container.md:385
#, fuzzy
#| msgid "# Control structures"
msgid "## Random-access iterators"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/guide-conditions.md:4 doc/guide-ffi.md:4 doc/guide-lifetimes.md:4
-#: doc/guide-macros.md:4 doc/guide-rustpkg.md:4 doc/guide-tasks.md:4
-#: doc/rust.md:4 doc/rustpkg.md:4 doc/tutorial.md:4
+#: src/doc/guide-conditions.md:4 src/doc/guide-ffi.md:4
+#: src/doc/guide-lifetimes.md:4 src/doc/guide-macros.md:4
+#: src/doc/guide-tasks.md:4 src/doc/rust.md:4 src/doc/tutorial.md:4
msgid "# Introduction"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/guide-ffi.md:2
+#: src/doc/guide-ffi.md:2
#, fuzzy
#| msgid "[The foreign function interface][ffi]"
msgid "% The Rust Foreign Function Interface Guide"
msgstr "[他言語間インターフェース (foreign function inferface)][ffi]"
#. type: Plain text
-#: doc/guide-ffi.md:16
+#: src/doc/guide-ffi.md:16
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~~ {.ignore} use std::libc::size_t;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/guide-ffi.md:48
+#: src/doc/guide-ffi.md:48
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~~ {.ignore} use std::libc::{c_int, size_t};"
"use std::task::spawn;"
#. type: Plain text
-#: doc/guide-ffi.md:168 doc/tutorial.md:875
+#: src/doc/guide-ffi.md:145
+#, fuzzy
+#| msgid "## Structs"
+msgid "# Stack management"
+msgstr "## 構造体"
+
+#. type: Plain text
+#: src/doc/guide-ffi.md:168 src/doc/tutorial.md:885
msgid "# Destructors"
msgstr "# デストラクタ"
#. type: Plain text
-#: doc/guide-ffi.md:333
+#: src/doc/guide-ffi.md:264
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "A basic example is:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/guide-ffi.md:323
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"struct RustObject {\n"
+" a: i32,\n"
+" // other members\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-ffi.md:390
+#, fuzzy
+#| msgid "## Freezing"
+msgid "# Linking"
+msgstr "## 凍結"
+
+#. type: Plain text
+#: src/doc/guide-ffi.md:437
+#, fuzzy
+#| msgid "# Vectors and strings"
+msgid "## The `link_args` attribute"
+msgstr "# ベクタと文字列"
+
+#. type: Plain text
+#: src/doc/guide-ffi.md:459
+#, fuzzy
+#| msgid "## Conventions"
+msgid "# Unsafe blocks"
+msgstr "## 本書の表記について"
+
+#. type: Plain text
+#: src/doc/guide-ffi.md:470
#, fuzzy
#| msgid "~~~~ let square = |x: int| -> uint { (x * x) as uint }; ~~~~"
msgid "~~~~ unsafe fn kaboom(ptr: *int) -> int { *ptr } ~~~~"
"~~~~~~~~\n"
#. type: Plain text
-#: doc/guide-ffi.md:344
+#: src/doc/guide-ffi.md:481
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~{.ignore} use std::libc;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/guide-ffi.md:363
+#: src/doc/guide-ffi.md:500
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~{.ignore} use std::libc; use std::ptr;"
msgstr ""
"~~~~\n"
"use std::task::spawn;"
+
+#. type: Plain text
+#: src/doc/guide-ffi.md:516
+#, fuzzy
+#| msgid "## Using the rust tool"
+msgid "# Foreign calling conventions"
+msgstr "## `rust` コマンドを利用する"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/guide-conditions.md:4 doc/guide-ffi.md:4 doc/guide-lifetimes.md:4
-#: doc/guide-macros.md:4 doc/guide-rustpkg.md:4 doc/guide-tasks.md:4
-#: doc/rust.md:4 doc/rustpkg.md:4 doc/tutorial.md:4
+#: src/doc/guide-conditions.md:4 src/doc/guide-ffi.md:4
+#: src/doc/guide-lifetimes.md:4 src/doc/guide-macros.md:4
+#: src/doc/guide-tasks.md:4 src/doc/rust.md:4 src/doc/tutorial.md:4
msgid "# Introduction"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/guide-lifetimes.md:2
+#: src/doc/guide-lifetimes.md:2
#, fuzzy
#| msgid "% The Rust Language Tutorial"
msgid "% The Rust References and Lifetimes Guide"
msgstr "% Rust 言語チュートリアル"
#. type: Plain text
-#: doc/guide-lifetimes.md:26
+#: src/doc/guide-lifetimes.md:26
#, fuzzy
#| msgid "## A minimal example"
msgid "# By example"
msgstr "## 最小限の例"
#. type: Plain text
-#: doc/guide-lifetimes.md:33
+#: src/doc/guide-lifetimes.md:33
#, fuzzy
#| msgid "As an example, consider a simple struct type, `Point`:"
msgid "As an example, consider a simple struct type `Point`:"
msgstr "例として、シンプルな構造体型の `Point` について考えます。"
#. type: Plain text
-#: doc/guide-lifetimes.md:41
+#: src/doc/guide-lifetimes.md:37
+#, fuzzy
+#| msgid ""
+#| "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: "
+#| "20f }; println(fmt!(\"%f\", point.x)); ~~~"
+msgid "~~~ struct Point {x: f64, y: f64} ~~~"
+msgstr ""
+"~~~\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let point = &@~Point { x: 10f, y: 20f };\n"
+"println(fmt!(\"%f\", point.x));\n"
+"~~~"
+
+#. type: Plain text
+#: src/doc/guide-lifetimes.md:41
#, fuzzy
#| msgid ""
#| "We can use this simple definition to allocate points in many different "
"なった場所に `Point` 型のオブジェクトを割り当てています。"
#. type: Plain text
-#: doc/guide-lifetimes.md:48
+#: src/doc/guide-lifetimes.md:48
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-lifetimes.md:60
+#: src/doc/guide-lifetimes.md:60
#, fuzzy
#| msgid ""
#| "Suppose we want to write a procedure that computes the distance between "
"です。"
#. type: Plain text
-#: doc/guide-lifetimes.md:72 doc/tutorial.md:1394
+#: src/doc/guide-lifetimes.md:72 src/doc/tutorial.md:1409
msgid "Now we can call `compute_distance()` in various ways:"
msgstr ""
"上記の `compute_distance()` 関数は、様々な方法で呼び出すことができます。"
#. type: Plain text
-#: doc/guide-lifetimes.md:82
+#: src/doc/guide-lifetimes.md:82
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-lifetimes.md:89
+#: src/doc/guide-lifetimes.md:89
#, fuzzy
#| msgid ""
#| "Here the `&` operator is used to take the address of the variable "
"(_borrowing_) と呼びます。"
#. type: Plain text
-#: doc/guide-lifetimes.md:95
+#: src/doc/guide-lifetimes.md:95
#, fuzzy
#| msgid ""
#| "In the case of the boxes `managed_box` and `owned_box`, however, no "
"す。"
#. type: Plain text
-#: doc/guide-lifetimes.md:105
+#: src/doc/guide-lifetimes.md:105
#, fuzzy
#| msgid ""
#| "Whenever a value is borrowed, there are some limitations on what you can "
"コープを抜ける) を待たなければなりません。"
#. type: Plain text
-#: doc/guide-lifetimes.md:114
+#: src/doc/guide-lifetimes.md:114
#, fuzzy
#| msgid ""
#| "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: "
"~~~"
#. type: Plain text
-#: doc/guide-lifetimes.md:124
+#: src/doc/guide-lifetimes.md:124
#, fuzzy
#| msgid ""
#| "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: "
"~~~"
#. type: Plain text
-#: doc/guide-lifetimes.md:134
+#: src/doc/guide-lifetimes.md:134
#, fuzzy
#| msgid ""
#| "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: "
"~~~"
#. type: Plain text
-#: doc/guide-lifetimes.md:180
+#: src/doc/guide-lifetimes.md:180
#, fuzzy
#| msgid "# Borrowed pointers"
msgid "# Borrowing managed boxes and rooting"
msgstr "# 借用ポインタ"
#. type: Plain text
-#: doc/guide-lifetimes.md:262
+#: src/doc/guide-lifetimes.md:262
#, fuzzy
#| msgid "# Borrowed pointers"
msgid "# Borrowing owned boxes"
msgstr "# 借用ポインタ"
#. type: Plain text
-#: doc/guide-lifetimes.md:367
+#: src/doc/guide-lifetimes.md:367
#, fuzzy
#| msgid "# Borrowed pointers"
msgid "# Borrowing and enums"
msgstr "# 借用ポインタ"
#. type: Plain text
-#: doc/guide-lifetimes.md:477
+#: src/doc/guide-lifetimes.md:477
#, fuzzy
#| msgid "# Dereferencing pointers"
msgid "# Returning references"
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/guide-lifetimes.md:490
+#: src/doc/guide-lifetimes.md:490
#, fuzzy
#| msgid ""
#| "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: "
"~~~"
#. type: Plain text
-#: doc/guide-lifetimes.md:659
+#: src/doc/guide-lifetimes.md:533
+#, fuzzy, no-wrap
+#| msgid "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: 20f }; println(fmt!(\"%f\", point.x)); ~~~"
+msgid ""
+"~~~ {.ignore}\n"
+"struct Point {x: f64, y: f64}\n"
+"fn get_x_sh(p: @Point) -> &f64 {\n"
+" &p.x // Error reported here\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let point = &@~Point { x: 10f, y: 20f };\n"
+"println(fmt!(\"%f\", point.x));\n"
+"~~~"
+
+#. type: Plain text
+#: src/doc/guide-lifetimes.md:659
#, fuzzy
#| msgid "## Conventions"
msgid "# Conclusion"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/guide-conditions.md:4 doc/guide-ffi.md:4 doc/guide-lifetimes.md:4
-#: doc/guide-macros.md:4 doc/guide-rustpkg.md:4 doc/guide-tasks.md:4
-#: doc/rust.md:4 doc/rustpkg.md:4 doc/tutorial.md:4
+#: src/doc/guide-conditions.md:4 src/doc/guide-ffi.md:4
+#: src/doc/guide-lifetimes.md:4 src/doc/guide-macros.md:4
+#: src/doc/guide-tasks.md:4 src/doc/rust.md:4 src/doc/tutorial.md:4
msgid "# Introduction"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/guide-macros.md:2
+#: src/doc/guide-macros.md:2
#, fuzzy
#| msgid "% The Rust Language Tutorial"
msgid "% The Rust Macros Guide"
msgstr "% Rust 言語チュートリアル"
#. type: Plain text
-#: doc/guide-macros.md:67
+#: src/doc/guide-macros.md:67
#, fuzzy
#| msgid "## Do syntax"
msgid "# Invocation syntax"
msgstr "## do 構文"
#. type: Plain text
-#: doc/guide-macros.md:100
+#: src/doc/guide-macros.md:100
#, fuzzy
#| msgid "# Introduction"
msgid "## Invocation location"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/guide-macros.md:115
+#: src/doc/guide-macros.md:115
#, fuzzy
#| msgid "## Traits"
msgid "# Transcription syntax"
msgstr "## トレイト"
#. type: Plain text
-#: doc/guide-macros.md:135
+#: src/doc/guide-macros.md:135
#, fuzzy
#| msgid "# Introduction"
msgid "## Interpolation location"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/guide-macros.md:143
+#: src/doc/guide-macros.md:143
#, fuzzy
#| msgid "# Introduction"
msgid "## Invocation"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/guide-macros.md:181
+#: src/doc/guide-macros.md:181
#, fuzzy
#| msgid "## Traits"
msgid "### Transcription"
msgstr "## トレイト"
#. type: Plain text
-#: doc/guide-macros.md:193
+#: src/doc/guide-macros.md:193
#, fuzzy
#| msgid "## Pattern matching"
msgid "## Parsing limitations"
msgstr "## パターンマッチ"
#. type: Plain text
-#: doc/guide-macros.md:212
+#: src/doc/guide-macros.md:212
#, fuzzy
#| msgid "## Pattern matching"
msgid "# Macro argument pattern matching"
msgstr "## パターンマッチ"
#. type: Plain text
-#: doc/guide-macros.md:214
+#: src/doc/guide-macros.md:214
#, fuzzy
#| msgid "## Conventions"
msgid "## Motivation"
msgstr "## 本書の表記について"
+
+#. type: Plain text
+#: src/doc/guide-macros.md:216
+#, fuzzy
+#| msgid "## Primitive types and literals"
+msgid "Now consider code like the following:"
+msgstr "## プリミティブ型とリテラル"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/guide-pointers.md:2
+#: src/doc/guide-pointers.md:2
#, fuzzy
#| msgid "% The Rust Language Tutorial"
msgid "% The Rust Pointer Guide"
msgstr "% Rust 言語チュートリアル"
#. type: Plain text
-#: doc/guide-pointers.md:21
+#: src/doc/guide-pointers.md:21
#, fuzzy
#| msgid "~~~~ let square = |x: int| -> uint { (x * x) as uint }; ~~~~"
msgid "~~~rust fn succ(x: &int) -> int { *x + 1 } ~~~"
"~~~~~~~~\n"
#. type: Plain text
-#: doc/guide-pointers.md:58
+#: src/doc/guide-pointers.md:31
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"~~~rust{.ignore}\n"
+"fn main() {\n"
+" let number = 5;\n"
+" let succ_number = succ(number);\n"
+" println!(\"{}\", succ_number);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:50
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"~~~rust\n"
+"# fn succ(x: &int) -> int { *x + 1 }\n"
+"fn main() {\n"
+" let number = 5;\n"
+" let succ_number = succ(&number);\n"
+" println!(\"{}\", succ_number);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:58
#, fuzzy
#| msgid "~~~~ let square = |x: int| -> uint { (x * x) as uint }; ~~~~"
msgid "~~~rust fn succ(x: int) -> int { x + 1 }"
"~~~~~~~~\n"
#. type: Plain text
-#: doc/guide-pointers.md:115
+#: src/doc/guide-pointers.md:65
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"fn main() {\n"
+" let number = 5;\n"
+" let succ_number = succ(number);\n"
+" println!(\"{}\", succ_number);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:109
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"~~~rust\n"
+"# fn transform(p: Point) -> Point { p }\n"
+"struct Point {\n"
+" x: int,\n"
+" y: int,\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:115
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-pointers.md:129
+#: src/doc/guide-pointers.md:129
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-pointers.md:145
+#: src/doc/guide-pointers.md:141 src/doc/guide-pointers.md:221
+#: src/doc/guide-pointers.md:238 src/doc/guide-pointers.md:300
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~rust\n"
+"struct Point {\n"
+" x: int,\n"
+" y: int,\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:145
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-pointers.md:152
+#: src/doc/guide-pointers.md:152
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-pointers.md:162
+#: src/doc/guide-pointers.md:162
#, fuzzy
#| msgid "# Borrowed pointers"
msgid "# Owned Pointers"
msgstr "# 借用ポインタ"
#. type: Plain text
-#: doc/guide-pointers.md:175
+#: src/doc/guide-pointers.md:175
#, fuzzy
msgid "## References to Traits"
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/guide-pointers.md:181
+#: src/doc/guide-pointers.md:181
#, fuzzy
#| msgid "# Data structures"
msgid "## Recursive Data Structures"
msgstr "# データ構造"
#. type: Plain text
-#: doc/guide-pointers.md:229
+#: src/doc/guide-pointers.md:189
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~rust\n"
+"enum List<T> {\n"
+" Nil,\n"
+" Cons(T, ~List<T>),\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:195
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"fn main() {\n"
+" let list: List<int> = Cons(1, ~Cons(2, ~Cons(3, ~Nil)));\n"
+" println!(\"{:?}\", list);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:215
+#, fuzzy
+msgid "For example, this will work:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:229
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"fn main() {\n"
" let a = Point { x: 10, y: 20 };\n"
-" do spawn {\n"
+" spawn(proc() {\n"
" println!(\"{}\", a.x);\n"
-" }\n"
+" });\n"
"}\n"
"~~~\n"
msgstr ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-pointers.md:246
+#: src/doc/guide-pointers.md:246
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"fn main() {\n"
" let a = ~Point { x: 10, y: 20 };\n"
-" do spawn {\n"
+" spawn(proc() {\n"
" println!(\"{}\", a.x);\n"
-" }\n"
+" });\n"
"}\n"
"~~~\n"
msgstr ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-pointers.md:251
+#: src/doc/guide-pointers.md:251
#, fuzzy
#| msgid "## Managed boxes"
msgid "# Managed Pointers"
msgstr "## マネージドボックス"
#. type: Plain text
-#: doc/guide-pointers.md:277
+#: src/doc/guide-pointers.md:269
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~rust{.ignore}\n"
+"struct Point {\n"
+" x: int,\n"
+" y: int,\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:277
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-pointers.md:308
+#: src/doc/guide-pointers.md:308
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-pointers.md:326 doc/tutorial.md:1345
+#: src/doc/guide-pointers.md:326 src/doc/tutorial.md:1360
#, fuzzy
msgid "# References"
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/guide-pointers.md:336
+#: src/doc/guide-pointers.md:336
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~rust use std::num::sqrt;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/guide-pointers.md:352
+#: src/doc/guide-pointers.md:341
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"struct Point {\n"
+" x: f32,\n"
+" y: f32,\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:352
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/guide-pointers.md:378
+#: src/doc/guide-pointers.md:378
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
msgid ""
"~~~~"
#. type: Plain text
-#: doc/guide-pointers.md:433
+#: src/doc/guide-pointers.md:396
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"~~~rust\n"
+"fn main() {\n"
+" let mut x = ~5;\n"
+" if *x < 10 {\n"
+" let y = &x;\n"
+" println!(\"Oh no: {:?}\", y);\n"
+" return;\n"
+" }\n"
+" *x -= 1;\n"
+" println!(\"Oh no: {:?}\", x);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:407
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"~~~rust{.ignore}\n"
+"fn main() {\n"
+" let mut x = ~5;\n"
+" if *x < 10 {\n"
+" let y = &x;\n"
+" *x -= 1;\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:415
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+" println!(\"Oh no: {:?}\", y);\n"
+" return;\n"
+" }\n"
+" *x -= 1;\n"
+" println!(\"Oh no: {:?}\", x);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:433
#, fuzzy
#| msgid "# Dereferencing pointers"
msgid "# Returning Pointers"
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/guide-pointers.md:444
+#: src/doc/guide-pointers.md:444
#, fuzzy, no-wrap
#| msgid "~~~~ let square = |x: int| -> uint { (x * x) as uint }; ~~~~"
msgid ""
"~~~~~~~~\n"
#. type: Plain text
-#: doc/guide-pointers.md:457 doc/guide-pointers.md:471
+#: src/doc/guide-pointers.md:450
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"fn main() {\n"
+" let x = ~5;\n"
+" let y = foo(x);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:457 src/doc/guide-pointers.md:471
#, fuzzy, no-wrap
#| msgid "~~~~ let square = |x: int| -> uint { (x * x) as uint }; ~~~~"
msgid ""
"~~~~\n"
"let square = |x: int| -> uint { (x * x) as uint };\n"
"~~~~~~~~\n"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:463
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"fn main() {\n"
+" let x = ~5;\n"
+" let y = ~foo(x);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:477
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"fn main() {\n"
+" let x = ~5;\n"
+" let y = @foo(x);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-pointers.md:491
+#, fuzzy
+#| msgid "# Modules and crates"
+msgid "# Related Resources"
+msgstr "# モジュールとクレート"
+
+#. type: Bullet: '* '
+#: src/doc/guide-pointers.md:492
+#, fuzzy
+#| msgid "% The Rust Language Tutorial"
+msgid "[Lifetimes guide](guide-lifetimes.html)"
+msgstr "% Rust 言語チュートリアル"
--- /dev/null
+# Japanese translations for Rust package
+# Copyright (C) 2014 The Rust Project Developers
+# This file is distributed under the same license as the Rust package.
+# Automatically generated, 2014.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Rust 0.10-pre\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
+"PO-Revision-Date: 2014-02-03 08:13+0900\n"
+"Last-Translator: Automatically generated\n"
+"Language-Team: none\n"
+"Language: ja\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:18
+#, fuzzy
+#| msgid "## Using the rust tool"
+msgid "# What is the runtime?"
+msgstr "## `rust` コマンドを利用する"
+
+#. type: Bullet: '* '
+#: src/doc/guide-runtime.md:36
+#, fuzzy
+#| msgid "[Tasks and communication][tasks]"
+msgid "Task spawning"
+msgstr "[タスクと通信][tasks]"
+
+#. type: Bullet: '* '
+#: src/doc/guide-runtime.md:36
+#, fuzzy
+#| msgid "[Tasks and communication][tasks]"
+msgid "Task unwinding"
+msgstr "[タスクと通信][tasks]"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:38
+#, fuzzy
+#| msgid "## Using the rust tool"
+msgid "## What is the runtime accomplishing?"
+msgstr "## `rust` コマンドを利用する"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:64
+#, fuzzy
+#| msgid "# Introduction"
+msgid "# Architecture of the runtime"
+msgstr "# イントロダクション"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:110
+#, fuzzy
+#| msgid "[Tasks and communication][tasks]"
+msgid "## Task Spawning"
+msgstr "[タスクと通信][tasks]"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:138
+#, fuzzy
+#| msgid "# Introduction"
+msgid "# Implementations of the runtime"
+msgstr "# イントロダクション"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:149
+#, fuzzy
+#| msgid "## Using other crates"
+msgid "## 1:1 - using `libnative`"
+msgstr "## 他のクレートの利用"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:169
+#, fuzzy
+#| msgid "## Using other crates"
+msgid "## M:N - using `libgreen`"
+msgstr "## 他のクレートの利用"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:231
+#, fuzzy
+#| msgid ""
+#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello "
+#| "\" + world::explore()); } ~~~~"
+msgid "~~~{.rust} fn main() {} ~~~"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:236
+#, fuzzy
+#| msgid "~~~~ {.ignore} let foo = 10;"
+msgid "~~~{.rust} extern mod green;"
+msgstr ""
+"~~~~ {.ignore}\n"
+"let foo = 10;"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:246
+#, fuzzy
+#| msgid ""
+#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello "
+#| "\" + world::explore()); } ~~~~"
+msgid "fn main() {} ~~~"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/guide-runtime.md:251
+#, fuzzy
+#| msgid "## Using the rust tool"
+msgid "# Finding the runtime"
+msgstr "## `rust` コマンドを利用する"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/guide-conditions.md:4 doc/guide-ffi.md:4 doc/guide-lifetimes.md:4
-#: doc/guide-macros.md:4 doc/guide-rustpkg.md:4 doc/guide-tasks.md:4
-#: doc/rust.md:4 doc/rustpkg.md:4 doc/tutorial.md:4
+#: src/doc/guide-conditions.md:4 src/doc/guide-ffi.md:4
+#: src/doc/guide-lifetimes.md:4 src/doc/guide-macros.md:4
+#: src/doc/guide-tasks.md:4 src/doc/rust.md:4 src/doc/tutorial.md:4
msgid "# Introduction"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/guide-tasks.md:2
+#: src/doc/guide-tasks.md:2
#, fuzzy
#| msgid "[Tasks and communication][tasks]"
msgid "% The Rust Tasks and Communication Guide"
msgstr "[タスクと通信][tasks]"
#. type: Plain text
-#: doc/guide-tasks.md:64
+#: src/doc/guide-tasks.md:64
#, fuzzy
#| msgid "# Syntax basics"
msgid "# Basics"
msgstr "# 基本的な構文"
#. type: Plain text
-#: doc/guide-tasks.md:73 doc/guide-tasks.md:132
+#: src/doc/guide-tasks.md:73 src/doc/guide-tasks.md:127
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~~ # use std::task::spawn;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/guide-tasks.md:113
+#: src/doc/guide-tasks.md:108
#, fuzzy
#| msgid "## Conditionals"
msgid "## Communication"
msgstr "## 条件式"
#. type: Plain text
-#: doc/guide-tasks.md:214
+#: src/doc/guide-tasks.md:209
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~ # use std::task::spawn;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/guide-tasks.md:246
+#: src/doc/guide-tasks.md:241
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~ # use std::task::spawn; # use std::vec;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/guide-tasks.md:327
+#: src/doc/guide-tasks.md:322
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~ # use std::vec; # use std::rand; use extra::arc::Arc;"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/guide-testing.md:2
+#: src/doc/guide-testing.md:2
#, fuzzy
#| msgid "% The Rust Language Tutorial"
msgid "% The Rust Testing Guide"
msgstr "% Rust 言語チュートリアル"
#. type: Plain text
-#: doc/guide-testing.md:4
+#: src/doc/guide-testing.md:4
#, fuzzy
#| msgid "# Getting started"
msgid "# Quick start"
msgstr "# はじめに"
#. type: Plain text
-#: doc/guide-testing.md:127 doc/tutorial.md:776
+#: src/doc/guide-testing.md:11
+#, fuzzy, no-wrap
+#| msgid "~~~~ let square = |x: int| -> uint { (x * x) as uint }; ~~~~"
+msgid ""
+"~~~\n"
+"fn return_two() -> int {\n"
+" 2\n"
+"}\n"
+msgstr ""
+"~~~~\n"
+"let square = |x: int| -> uint { (x * x) as uint };\n"
+"~~~~~~~~\n"
+
+#. type: Plain text
+#: src/doc/guide-testing.md:97
+#, fuzzy
+#| msgid "## Structs"
+msgid "## Parallelism"
+msgstr "## 構造体"
+
+#. type: Plain text
+#: src/doc/guide-testing.md:127 src/doc/tutorial.md:786
#, fuzzy
-#| msgid "## A minimal example"
msgid "For example:"
msgstr "## 最小限の例"
#. type: Plain text
-#: doc/guide-testing.md:131
+#: src/doc/guide-testing.md:131
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~ extern mod extra; use std::vec;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/guide-testing.md:167
+#: src/doc/guide-testing.md:150
+#, fuzzy
+#| msgid "# Dereferencing pointers"
+msgid "Advice on writing benchmarks:"
+msgstr "# ポインタのデリファレンス"
+
+#. type: Plain text
+#: src/doc/guide-testing.md:167
#, fuzzy
#| msgid "## Tuples"
msgid "## Examples"
msgstr "## タプル"
#. type: Plain text
-#: doc/guide-testing.md:169
+#: src/doc/guide-testing.md:169
#, fuzzy
#| msgid "## Tuple structs"
msgid "### Typical test run"
msgstr "## タプル構造体"
#. type: Plain text
-#: doc/guide-testing.md:197
+#: src/doc/guide-testing.md:183
+#, fuzzy
+#| msgid "## Structs"
+msgid "### Test run with failures"
+msgstr "## 構造体"
+
+#. type: Plain text
+#: src/doc/guide-testing.md:197
#, fuzzy
#| msgid "# Dereferencing pointers"
msgid "### Running ignored tests"
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/guide-testing.md:235
+#: src/doc/guide-testing.md:209
+#, fuzzy
+#| msgid "# Dereferencing pointers"
+msgid "### Running a subset of tests"
+msgstr "# ポインタのデリファレンス"
+
+#. type: Plain text
+#: src/doc/guide-testing.md:223
+#, fuzzy
+#| msgid "# Dereferencing pointers"
+msgid "### Running benchmarks"
+msgstr "# ポインタのデリファレンス"
+
+#. type: Plain text
+#: src/doc/guide-testing.md:235
#, fuzzy
#| msgid "## Declaring and implementing traits"
msgid "## Saving and ratcheting metrics"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-14 21:02+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-14 21:02+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/index.md:2
+#: src/doc/index.md:2
#, fuzzy
#| msgid "## Using the rust tool"
msgid "% Rust documentation"
msgstr "## `rust` コマンドを利用する"
+#. type: Bullet: '* '
+#: src/doc/index.md:25
+#, fuzzy
+#| msgid "[Containers and iterators](tutorial-container.html)"
+msgid "[Pointers](guide-pointers.html)"
+msgstr "[コンテナとイテレータ](tutorial-container.html)"
+
+#. type: Bullet: '* '
+#: src/doc/index.md:25
+#, fuzzy
+#| msgid "% The Rust Language Tutorial"
+msgid "[References and Lifetimes](guide-lifetimes.html)"
+msgstr "% Rust 言語チュートリアル"
+
+#. type: Bullet: '* '
+#: src/doc/index.md:25
+#, fuzzy
+#| msgid "[Containers and iterators](tutorial-container.html)"
+msgid "[Containers and Iterators](guide-container.html)"
+msgstr "[コンテナとイテレータ](tutorial-container.html)"
+
+#. type: Bullet: '* '
+#: src/doc/index.md:25
+#, fuzzy
+#| msgid "[Tasks and communication][tasks]"
+msgid "[Tasks and Communication](guide-tasks.html)"
+msgstr "[タスクと通信][tasks]"
+
+#. type: Bullet: '* '
+#: src/doc/index.md:25
+#, fuzzy
+#| msgid "[The foreign function interface][ffi]"
+msgid "[Foreign Function Interface](guide-ffi.html)"
+msgstr "[他言語間インターフェース (foreign function inferface)][ffi]"
+
+#. type: Bullet: '* '
+#: src/doc/index.md:25
+#, fuzzy
+#| msgid "[Macros][macros]"
+msgid "[Macros](guide-macros.html)"
+msgstr "[マクロ][macros]"
+
+#. type: Bullet: '* '
+#: src/doc/index.md:25
+#, fuzzy
+#| msgid "[Macros][macros]"
+msgid "[Packaging](guide-rustpkg.html)"
+msgstr "[マクロ][macros]"
+
+#. type: Bullet: '* '
+#: src/doc/index.md:25
+#, fuzzy
+#| msgid "% The Rust Language Tutorial"
+msgid "[Testing](guide-testing.html)"
+msgstr "% Rust 言語チュートリアル"
+
+#. type: Bullet: '* '
+#: src/doc/index.md:25
+#, fuzzy
+#| msgid "[Containers and iterators](tutorial-container.html)"
+msgid "[Conditions](guide-conditions.html)"
+msgstr "[コンテナとイテレータ](tutorial-container.html)"
+
+#. type: Bullet: '* '
+#: src/doc/index.md:25
+#, fuzzy
+#| msgid "% The Rust Language Tutorial"
+msgid "[Rust's Runtime](guide-runtime.html)"
+msgstr "% Rust 言語チュートリアル"
+
#. type: Plain text
-#: doc/index.md:26
+#: src/doc/index.md:27
#, fuzzy
#| msgid "## Using other crates"
msgid "# Libraries"
msgstr "## 他のクレートの利用"
+
+#. type: Plain text
+#: src/doc/index.md:58
+#, fuzzy
+#| msgid "## Conventions"
+msgid "# External resources"
+msgstr "## 本書の表記について"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.8\n"
-"POT-Creation-Date: 2014-01-14 21:02+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2013-08-05 19:40+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/guide-conditions.md:4 doc/guide-ffi.md:4 doc/guide-lifetimes.md:4
-#: doc/guide-macros.md:4 doc/guide-rustpkg.md:4 doc/guide-tasks.md:4
-#: doc/rust.md:4 doc/rustpkg.md:4 doc/tutorial.md:4
+#: src/doc/complement-cheatsheet.md:115 src/doc/rust.md:3019
+#, fuzzy
+msgid "# Type system"
+msgstr "## タプル"
+
+#. type: Plain text
+#: src/doc/guide-conditions.md:4 src/doc/guide-ffi.md:4
+#: src/doc/guide-lifetimes.md:4 src/doc/guide-macros.md:4
+#: src/doc/guide-tasks.md:4 src/doc/rust.md:4 src/doc/tutorial.md:4
msgid "# Introduction"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/rust.md:2
+#: src/doc/rust.md:2
#, fuzzy
#| msgid "% The Rust Language Tutorial"
msgid "% The Rust Reference Manual"
msgstr "% Rust 言語チュートリアル"
#. type: Plain text
-#: doc/rust.md:54
+#: src/doc/rust.md:54
#, fuzzy
#| msgid "## Conventions"
msgid "# Notation"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/rust.md:91
+#: src/doc/rust.md:91
#, fuzzy
#| msgid "# Introduction"
msgid "## Unicode productions"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/rust.md:98
+#: src/doc/rust.md:98
#, fuzzy
#| msgid "## Using other crates"
msgid "## String table productions"
msgstr "## 他のクレートの利用"
#. type: Plain text
-#: doc/rust.md:113
+#: src/doc/rust.md:113
#, fuzzy
#| msgid "# Data structures"
msgid "# Lexical structure"
msgstr "# データ構造"
#. type: Plain text
-#: doc/rust.md:152
+#: src/doc/rust.md:123
+#, fuzzy
+#| msgid "# Introduction"
+msgid "## Special Unicode Productions"
+msgstr "# イントロダクション"
+
+#. type: Plain text
+#: src/doc/rust.md:128
+#, fuzzy
+#| msgid "## Operators"
+msgid "### Identifiers"
+msgstr "## 演算子"
+
+#. type: Plain text
+#: src/doc/rust.md:141
+#, fuzzy
+#| msgid "## Using other crates"
+msgid "### Delimiter-restricted productions"
+msgstr "## 他のクレートの利用"
+
+#. type: Plain text
+#: src/doc/rust.md:152
#, fuzzy
#| msgid "## Conventions"
msgid "## Comments"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/rust.md:190
+#: src/doc/rust.md:190
#, fuzzy
#| msgid "## Tuples"
msgid "## Tokens"
msgstr "## タプル"
#. type: Plain text
-#: doc/rust.md:226
+#: src/doc/rust.md:202
+#, fuzzy
+#| msgid "## Tuples"
+msgid "### Keywords"
+msgstr "## タプル"
+
+#. type: Plain text
+#: src/doc/rust.md:204
+#, fuzzy
+#| msgid "## Primitive types and literals"
+msgid "The keywords are the following strings:"
+msgstr "## プリミティブ型とリテラル"
+
+#. type: Plain text
+#: src/doc/rust.md:226
#, fuzzy
#| msgid "## Operators"
msgid "### Literals"
msgstr "## 演算子"
#. type: Plain text
-#: doc/rust.md:238
+#: src/doc/rust.md:238
#, fuzzy
#| msgid "# Vectors and strings"
msgid "#### Character and string literals"
msgstr "# ベクタと文字列"
#. type: Plain text
-#: doc/rust.md:345
+#: src/doc/rust.md:307
+#, fuzzy
+#| msgid "# Vectors and strings"
+msgid "Examples for string literals:"
+msgstr "# ベクタと文字列"
+
+#. type: Plain text
+#: src/doc/rust.md:320
+#, fuzzy
+#| msgid "# Control structures"
+msgid "#### Number literals"
+msgstr "# 制御構造"
+
+#. type: Plain text
+#: src/doc/rust.md:345
#, fuzzy
#| msgid "# Control structures"
msgid "##### Integer literals"
msgstr "# 制御構造"
#. type: Plain text
-#: doc/rust.md:459
+#: src/doc/rust.md:347
+#, fuzzy
+#| msgid "# Vectors and strings"
+msgid "An _integer literal_ has one of four forms:"
+msgstr "# ベクタと文字列"
+
+#. type: Plain text
+#: src/doc/rust.md:375
+#, fuzzy
+#| msgid "# Vectors and strings"
+msgid "Examples of integer literals of various forms:"
+msgstr "# ベクタと文字列"
+
+#. type: Plain text
+#: src/doc/rust.md:389
+#, fuzzy
+#| msgid "# Control structures"
+msgid "##### Floating-point literals"
+msgstr "# 制御構造"
+
+#. type: Plain text
+#: src/doc/rust.md:391
+#, fuzzy
+#| msgid "# Vectors and strings"
+msgid "A _floating-point literal_ has one of two forms:"
+msgstr "# ベクタと文字列"
+
+#. type: Plain text
+#: src/doc/rust.md:404
+#, fuzzy
+#| msgid "# Vectors and strings"
+msgid "Examples of floating-point literals of various forms:"
+msgstr "# ベクタと文字列"
+
+#. type: Plain text
+#: src/doc/rust.md:413
+#, fuzzy
+#| msgid "# Control structures"
+msgid "##### Unit and boolean literals"
+msgstr "# 制御構造"
+
+#. type: Plain text
+#: src/doc/rust.md:418
+#, fuzzy
+#| msgid "## Tuples"
+msgid "### Symbols"
+msgstr "## タプル"
+
+#. type: Plain text
+#: src/doc/rust.md:459
#, fuzzy
#| msgid "~~~~ {.ignore} let foo = 10;"
msgid "~~~~ {.ignore} x; x::y::z; ~~~~"
"let foo = 10;"
#. type: Plain text
-#: doc/rust.md:479
+#: src/doc/rust.md:468
+#, fuzzy
+#| msgid "# Vectors and strings"
+msgid "Two examples of paths with type arguments:"
+msgstr "# ベクタと文字列"
+
+#. type: Plain text
+#: src/doc/rust.md:479
#, fuzzy
#| msgid "## Syntax extensions"
msgid "# Syntax extensions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:524
+#: src/doc/rust.md:497
+#, fuzzy
+#| msgid "## Syntax extensions"
+msgid "## Macros"
+msgstr "## 構文拡張"
+
+#. type: Plain text
+#: src/doc/rust.md:525
#, fuzzy
#| msgid "## A minimal example"
msgid "### Macro By Example"
msgstr "## 最小限の例"
#. type: Plain text
-#: doc/rust.md:560
+#: src/doc/rust.md:561
#, fuzzy
#| msgid "## Pattern matching"
msgid "### Parsing limitations"
msgstr "## パターンマッチ"
#. type: Plain text
-#: doc/rust.md:579
+#: src/doc/rust.md:580
#, fuzzy
#| msgid "# Modules and crates"
msgid "# Crates and source files"
msgstr "# モジュールとクレート"
#. type: Plain text
-#: doc/rust.md:626
+#: src/doc/rust.md:627
#, fuzzy
#| msgid "// Turn on a warning #[warn(non_camel_case_types)]"
msgid "// Turn on a warning #[ warn(non_camel_case_types) ]; ~~~~"
"#[warn(non_camel_case_types)]"
#. type: Plain text
-#: doc/rust.md:631
+#: src/doc/rust.md:632
#, fuzzy
#| msgid "# Vectors and strings"
msgid "# Items and attributes"
msgstr "# ベクタと文字列"
#. type: Plain text
-#: doc/rust.md:636
+#: src/doc/rust.md:637
#, fuzzy
#| msgid "## Operators"
msgid "## Items"
msgstr "## 演算子"
#. type: Plain text
-#: doc/rust.md:765
+#: src/doc/rust.md:674
+#, fuzzy
+#| msgid "## Tuples"
+msgid "### Type Parameters"
+msgstr "## タプル"
+
+#. type: Plain text
+#: src/doc/rust.md:685
+#, fuzzy
+#| msgid "## Tuples"
+msgid "### Modules"
+msgstr "## タプル"
+
+#. type: Plain text
+#: src/doc/rust.md:701
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of a module:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:753
+#, fuzzy
+#| msgid "## Structs"
+msgid "#### View items"
+msgstr "## 構造体"
+
+#. type: Plain text
+#: src/doc/rust.md:766
#, fuzzy
#| msgid "## Using other crates"
msgid "##### Extern mod declarations"
msgstr "## 他のクレートの利用"
#. type: Plain text
-#: doc/rust.md:788
+#: src/doc/rust.md:786
+#, fuzzy
+#| msgid "## Using other crates"
+msgid "Four examples of `extern mod` declarations:"
+msgstr "## 他のクレートの利用"
+
+#. type: Plain text
+#: src/doc/rust.md:789
#, fuzzy
#| msgid "~~~~ {.ignore} let foo = 10;"
msgid "~~~~ {.ignore} extern mod pcre;"
"let foo = 10;"
#. type: Plain text
-#: doc/rust.md:797
+#: src/doc/rust.md:798
#, fuzzy
#| msgid "## Conventions"
msgid "##### Use declarations"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/rust.md:827
+#: src/doc/rust.md:826
+#, fuzzy
+#| msgid "## Using other crates"
+msgid "An example of `use` declarations:"
+msgstr "## 他のクレートの利用"
+
+#. type: Plain text
+#: src/doc/rust.md:830
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~~ use std::num::sin; use std::option::{Some, None};"
"use std::task::spawn;"
#. type: Plain text
-#: doc/rust.md:900
+#: src/doc/rust.md:851
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of re-exporting:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:875
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of what will and will not work for `use` items:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:883
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} let foo = 10;"
+msgid ""
+"mod foo {\n"
+" extern mod extra;\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"let foo = 10;"
+
+#. type: Plain text
+#: src/doc/rust.md:901
+#, fuzzy
+#| msgid ""
+#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello "
+#| "\" + world::explore()); } ~~~~"
+msgid "fn main() {} ~~~~"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/rust.md:903
#, fuzzy
#| msgid "# Functions"
msgid "### Functions"
msgstr "# 関数"
#. type: Plain text
-#: doc/rust.md:930
+#: src/doc/rust.md:920
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of a function:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:926
+#, fuzzy, no-wrap
+#| msgid "~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+msgid ""
+"~~~~\n"
+"fn add(x: int, y: int) -> int {\n"
+" return x + y;\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~\n"
+"fn line(a: int, b: int, x: int) -> int { a * x + b }\n"
+"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+
+#. type: Plain text
+#: src/doc/rust.md:933
#, fuzzy
#| msgid "~~~ fn first((value, _): (int, f64)) -> int { value } ~~~"
msgid "~~~~ fn first((value, _): (int, int)) -> int { value } ~~~~"
"~~~"
#. type: Plain text
-#: doc/rust.md:933
+#: src/doc/rust.md:936
#, fuzzy
#| msgid "## Conventions"
msgid "#### Generic functions"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/rust.md:971
+#: src/doc/rust.md:974
#, fuzzy
#| msgid "~~~~ let square = |x: int| -> uint { (x * x) as uint }; ~~~~"
msgid "~~~~ fn id<T>(x: T) -> T { x } ~~~~"
"~~~~~~~~\n"
#. type: Plain text
-#: doc/rust.md:978
+#: src/doc/rust.md:981
#, fuzzy
#| msgid "## Conventions"
msgid "#### Unsafety"
msgstr "## 本書の表記について"
#. type: Bullet: ' - '
-#: doc/rust.md:985
+#: src/doc/rust.md:988
#, fuzzy
#| msgid "# Dereferencing pointers"
msgid "Dereferencing a [raw pointer](#pointer-types)."
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/rust.md:987
+#: src/doc/rust.md:990
#, fuzzy
#| msgid "## Conventions"
msgid "##### Unsafe functions"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/rust.md:992
+#: src/doc/rust.md:995
#, fuzzy
#| msgid "## Conventions"
msgid "##### Unsafe blocks"
msgstr "## 本書の表記について"
#. type: Bullet: '* '
-#: doc/rust.md:1034
+#: src/doc/rust.md:1037
#, fuzzy
#| msgid "# Data structures"
msgid "Data races"
msgstr "# データ構造"
#. type: Bullet: '* '
-#: doc/rust.md:1034
+#: src/doc/rust.md:1037
#, fuzzy
#| msgid "# Dereferencing pointers"
msgid "Dereferencing a null/dangling raw pointer"
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/rust.md:1049
+#: src/doc/rust.md:1052
#, fuzzy
#| msgid "## Conventions"
msgid "#### Diverging functions"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/rust.md:1096
+#: src/doc/rust.md:1088
+#, fuzzy, no-wrap
+#| msgid "~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+msgid ""
+"fn f(i: int) -> int {\n"
+" if i == 42 {\n"
+" return 42;\n"
+" }\n"
+" else {\n"
+" my_err(\"Bad number!\");\n"
+" }\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~\n"
+"fn line(a: int, b: int, x: int) -> int { a * x + b }\n"
+"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+
+#. type: Plain text
+#: src/doc/rust.md:1099
#, fuzzy
#| msgid "## Conventions"
msgid "#### Extern functions"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/rust.md:1125
+#: src/doc/rust.md:1128
#, fuzzy
#| msgid "## Conventions"
msgid "### Type definitions"
msgstr "## 本書の表記について"
+#. type: Bullet: '* '
+#: src/doc/rust.md:1138
+#, fuzzy
+#| msgid "# Closures"
+msgid "Whether the value represents integral or floating-point information."
+msgstr "# クロージャ"
+
#. type: Plain text
-#: doc/rust.md:1140
+#: src/doc/rust.md:1143
#, fuzzy
#| msgid "## Structs"
msgid "### Structures"
msgstr "## 構造体"
#. type: Plain text
-#: doc/rust.md:1150
+#: src/doc/rust.md:1147
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of a `struct` item and its use:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:1153
#, fuzzy
#| msgid ""
#| "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: "
"~~~"
#. type: Plain text
-#: doc/rust.md:1170
+#: src/doc/rust.md:1162
+#, fuzzy
+#| msgid ""
+#| "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: "
+#| "20f }; println(fmt!(\"%f\", point.x)); ~~~"
+msgid ""
+"~~~~ struct Point(int, int); let p = Point(10, 11); let px: int = match p "
+"{ Point(x, _) => x }; ~~~~"
+msgstr ""
+"~~~\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let point = &@~Point { x: 10f, y: 20f };\n"
+"println(fmt!(\"%f\", point.x));\n"
+"~~~"
+
+#. type: Plain text
+#: src/doc/rust.md:1173
#, fuzzy
#| msgid "## Enums"
msgid "### Enumerations"
msgstr "## 列挙型"
#. type: Plain text
-#: doc/rust.md:1204
+#: src/doc/rust.md:1180
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of an `enum` item and its use:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:1207
#, fuzzy
#| msgid "## Structs"
msgid "### Static items"
msgstr "## 構造体"
#. type: Plain text
-#: doc/rust.md:1240
+#: src/doc/rust.md:1243
#, fuzzy
#| msgid "# Move semantics"
msgid "#### Mutable statics"
msgstr "# ムーブセマンティクス"
#. type: Plain text
-#: doc/rust.md:1274
+#: src/doc/rust.md:1257
+#, fuzzy
+#| msgid ""
+#| "~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, "
+#| "b: int, x: int) -> () { a * x + b; }"
+msgid "~~~~ # fn atomic_add(_: &mut uint, _: uint) -> uint { 2 }"
+msgstr ""
+"~~~~\n"
+"fn line(a: int, b: int, x: int) -> int { a * x + b }\n"
+"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+
+#. type: Plain text
+#: src/doc/rust.md:1277
#, fuzzy
#| msgid "## Traits"
msgid "### Traits"
msgstr "## トレイト"
#. type: Plain text
-#: doc/rust.md:1363
+#: src/doc/rust.md:1366
#, fuzzy
#| msgid "Enum variants may also be structs. For example:"
msgid "Traits may inherit from other traits. For example, in"
msgstr "以下の例のように、列挙型バリアントを構造体にすることも可能です。"
#. type: Plain text
-#: doc/rust.md:1368
+#: src/doc/rust.md:1371
#, fuzzy
#| msgid ""
#| "~~~~ trait Shape { fn area(&self) -> f64; } trait Circle : Shape { fn "
"~~~~"
#. type: Plain text
-#: doc/rust.md:1377
+#: src/doc/rust.md:1380
#, fuzzy
#| msgid ""
#| "In type-parameterized functions, methods of the supertrait may be called "
"を参照してください。"
#. type: Plain text
-#: doc/rust.md:1386
+#: src/doc/rust.md:1389
#, fuzzy, no-wrap
#| msgid ""
#| "~~~\n"
"~~~\n"
#. type: Plain text
-#: doc/rust.md:1388 doc/tutorial.md:2508
+#: src/doc/rust.md:1391 src/doc/tutorial.md:2495
msgid "Likewise, supertrait methods may also be called on trait objects."
msgstr ""
"同様に、スーパートレイトのメソッドは、トレイトオブジェクトについても呼び出す"
"ことが可能です。"
#. type: Plain text
-#: doc/rust.md:1395
+#: src/doc/rust.md:1398
#, fuzzy
#| msgid ""
-#| "~~~ {.ignore} use std::f64::consts::pi; # trait Shape { fn "
-#| "area(&self) -> f64; } # trait Circle : Shape { fn radius(&self) -> f64; } "
-#| "# struct Point { x: f64, y: f64 } # struct CircleStruct { center: Point, "
-#| "radius: f64 } # impl Circle for CircleStruct { fn radius(&self) -> f64 "
-#| "{ (self.area() / pi).sqrt() } } # impl Shape for CircleStruct { fn "
-#| "area(&self) -> f64 { pi * square(self.radius) } }"
+#| "~~~ {.ignore} use std::f64::consts::pi; # trait Shape { fn area(&self) -> "
+#| "f64; } # trait Circle : Shape { fn radius(&self) -> f64; } # struct Point "
+#| "{ x: f64, y: f64 } # struct CircleStruct { center: Point, radius: f64 } # "
+#| "impl Circle for CircleStruct { fn radius(&self) -> f64 { (self.area() / "
+#| "pi).sqrt() } } # impl Shape for CircleStruct { fn area(&self) -> f64 { pi "
+#| "* square(self.radius) } }"
msgid ""
"~~~~ {.ignore} # trait Shape { fn area(&self) -> f64; } # trait Circle : "
"Shape { fn radius(&self) -> f64; } # impl Shape for int { fn area(&self) -> "
"radius) } }"
#. type: Plain text
-#: doc/rust.md:1399
+#: src/doc/rust.md:1402
#, fuzzy
#| msgid ""
#| "let concrete = @CircleStruct{center:Point{x:3f,y:4f},radius:5f}; let "
"~~~"
#. type: Plain text
-#: doc/rust.md:1401
+#: src/doc/rust.md:1404
#, fuzzy
#| msgid "# Introduction"
msgid "### Implementations"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/rust.md:1841
-#, fuzzy
-#| msgid "## Traits"
-msgid "#### Traits"
-msgstr "## トレイト"
+#: src/doc/rust.md:1420
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"struct Circle {\n"
+" radius: f64,\n"
+" center: Point,\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
#. type: Plain text
-#: doc/rust.md:1882
+#: src/doc/rust.md:1458
#, fuzzy
-#| msgid "## Operators"
-msgid "#### Operations"
-msgstr "## æ¼\94ç®\97å\90"
+#| msgid "## Conventions"
+msgid "### External blocks"
+msgstr "## æ\9c¬æ\9b¸ã\81®è¡¨è¨\98ã\81«ã\81¤ã\81\84ã\81¦"
#. type: Plain text
-#: doc/rust.md:1930
+#: src/doc/rust.md:1644 src/doc/rust.md:1665
#, fuzzy
-#| msgid "Our example crate declared this set of `link` attributes:"
-msgid "There are three different types of inline attributes:"
+#| msgid ""
+#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello "
+#| "\" + world::explore()); } ~~~~"
+msgid "# fn main() {} ~~~~"
msgstr ""
-"先ほどのクレートの例では、 `link` 属性は以下のように宣言されていました。"
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
#. type: Plain text
-#: doc/rust.md:1936
+#: src/doc/rust.md:1650
#, fuzzy
-#| msgid "## Freezing"
-msgid "### Deriving"
-msgstr "## 凍結"
+#| msgid "# Dereferencing pointers"
+msgid "### Re-exporting and Visibility"
+msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/rust.md:2038
+#: src/doc/rust.md:1674
#, fuzzy
-#| msgid "## Crates"
-msgid "### Compiler Features"
-msgstr "## ã\82¯ã\83¬ã\83¼ã\83\88"
+#| msgid "## Managed closures"
+msgid "### Glob imports and Visibility"
+msgstr "## ã\83\9eã\83\8dã\83¼ã\82¸ã\83\89ã\82¯ã\83ã\83¼ã\82¸ã\83£"
#. type: Plain text
-#: doc/rust.md:2126
+#: src/doc/rust.md:1684
#, fuzzy
-#| msgid "## Syntax extensions"
-msgid "# Statements and expressions"
-msgstr "## 構文拡張"
+#| msgid "# Vectors and strings"
+msgid "## Attributes"
+msgstr "# ベクタと文字列"
#. type: Plain text
-#: doc/rust.md:2138
+#: src/doc/rust.md:1706
#, fuzzy
-#| msgid "## Structs"
-msgid "## Statements"
-msgstr "## 構造体"
+#| msgid "# Vectors and strings"
+msgid "An example of attributes:"
+msgstr "# ベクタと文字列"
#. type: Plain text
-#: doc/rust.md:2147
+#: src/doc/rust.md:1754
#, fuzzy
-#| msgid "## Declaring and implementing traits"
-msgid "### Declaration statements"
-msgstr "## トレイトの宣言と実装"
+#| msgid "# Vectors and strings"
+msgid "### Lint check attributes"
+msgstr "# ベクタと文字列"
#. type: Plain text
-#: doc/rust.md:2152
+#: src/doc/rust.md:1823
#, fuzzy
-#| msgid "## Operators"
-msgid "#### Item declarations"
-msgstr "## æ¼\94ç®\97å\90"
+#| msgid "## Structs"
+msgid "### Language items"
+msgstr "## æ§\8bé\80 ä½\93"
#. type: Plain text
-#: doc/rust.md:2164
+#: src/doc/rust.md:1844
#, fuzzy
-#| msgid "## Using other crates"
-msgid "#### Slot declarations"
+#| msgid "## Traits"
+msgid "#### Traits"
+msgstr "## トレイト"
+
+#. type: Plain text
+#: src/doc/rust.md:1885
+#, fuzzy
+#| msgid "## Operators"
+msgid "#### Operations"
+msgstr "## 演算子"
+
+#. type: Plain text
+#: src/doc/rust.md:1920
+#, fuzzy
+#| msgid "# Vectors and strings"
+msgid "### Inline attributes"
+msgstr "# ベクタと文字列"
+
+#. type: Plain text
+#: src/doc/rust.md:1933
+#, fuzzy
+#| msgid "Our example crate declared this set of `link` attributes:"
+msgid "There are three different types of inline attributes:"
+msgstr ""
+"先ほどのクレートの例では、 `link` 属性は以下のように宣言されていました。"
+
+#. type: Plain text
+#: src/doc/rust.md:1939
+#, fuzzy
+#| msgid "## Freezing"
+msgid "### Deriving"
+msgstr "## 凍結"
+
+#. type: Plain text
+#: src/doc/rust.md:1953
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~~\n"
+"#[deriving(Eq, Clone)]\n"
+"struct Foo<T> {\n"
+" a: int,\n"
+" b: T\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/rust.md:2008
+#, fuzzy
+#| msgid "~~~~ use std::task::spawn;"
+msgid "~~~~ {.ignore} #[warn(unstable)];"
+msgstr ""
+"~~~~\n"
+"use std::task::spawn;"
+
+#. type: Plain text
+#: src/doc/rust.md:2037
+#, fuzzy
+#| msgid "## Crates"
+msgid "### Compiler Features"
+msgstr "## クレート"
+
+#. type: Plain text
+#: src/doc/rust.md:2125
+#, fuzzy
+#| msgid "## Syntax extensions"
+msgid "# Statements and expressions"
+msgstr "## 構文拡張"
+
+#. type: Plain text
+#: src/doc/rust.md:2137
+#, fuzzy
+#| msgid "## Structs"
+msgid "## Statements"
+msgstr "## 構造体"
+
+#. type: Plain text
+#: src/doc/rust.md:2146
+#, fuzzy
+#| msgid "## Declaring and implementing traits"
+msgid "### Declaration statements"
+msgstr "## トレイトの宣言と実装"
+
+#. type: Plain text
+#: src/doc/rust.md:2151
+#, fuzzy
+#| msgid "## Operators"
+msgid "#### Item declarations"
+msgstr "## 演算子"
+
+#. type: Plain text
+#: src/doc/rust.md:2163
+#, fuzzy
+#| msgid "## Using other crates"
+msgid "#### Slot declarations"
msgstr "## 他のクレートの利用"
#. type: Plain text
-#: doc/rust.md:2177
+#: src/doc/rust.md:2176
#, fuzzy
#| msgid "## Expressions and semicolons"
msgid "### Expression statements"
msgstr "## 式とセミコロン"
#. type: Plain text
-#: doc/rust.md:2184
+#: src/doc/rust.md:2183
#, fuzzy
#| msgid "## Expressions and semicolons"
msgid "## Expressions"
msgstr "## 式とセミコロン"
#. type: Plain text
-#: doc/rust.md:2238
+#: src/doc/rust.md:2223
+#, fuzzy
+#| msgid "# Closures"
+msgid "#### Moved and copied types"
+msgstr "# クロージャ"
+
+#. type: Plain text
+#: src/doc/rust.md:2233
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### Literal expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2251
+#: src/doc/rust.md:2246
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### Path expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2256
+#: src/doc/rust.md:2251
#, fuzzy
#| msgid "## Tuples"
msgid "### Tuple expressions"
msgstr "## タプル"
#. type: Plain text
-#: doc/rust.md:2268
+#: src/doc/rust.md:2263
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### Structure expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2320
+#: src/doc/rust.md:2288
+#, fuzzy
+#| msgid "## Syntax extensions"
+msgid "The following are examples of structure expressions:"
+msgstr "## 構文拡張"
+
+#. type: Plain text
+#: src/doc/rust.md:2315
#, fuzzy
#| msgid ""
#| "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: "
"~~~"
#. type: Plain text
-#: doc/rust.md:2341
+#: src/doc/rust.md:2317
+#, fuzzy
+#| msgid "## Conventions"
+msgid "### Block expressions"
+msgstr "## 本書の表記について"
+
+#. type: Plain text
+#: src/doc/rust.md:2335
+#, fuzzy
+#| msgid "## Syntax extensions"
+msgid "### Method-call expressions"
+msgstr "## 構文拡張"
+
+#. type: Plain text
+#: src/doc/rust.md:2346
#, fuzzy
#| msgid "## Operators"
msgid "### Field expressions"
msgstr "## 演算子"
#. type: Plain text
-#: doc/rust.md:2362
+#: src/doc/rust.md:2367
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### Vector expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2384
+#: src/doc/rust.md:2389
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### Index expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2400
+#: src/doc/rust.md:2405
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~~ {.ignore} # use std::task; # do task::spawn {"
"use std::task::spawn;"
#. type: Plain text
-#: doc/rust.md:2433
+#: src/doc/rust.md:2413
+#, fuzzy
+#| msgid "## Using other crates"
+msgid "### Unary operator expressions"
+msgstr "## 他のクレートの利用"
+
+#. type: Plain text
+#: src/doc/rust.md:2438
#, fuzzy
#| msgid "## Using other crates"
msgid "### Binary operator expressions"
msgstr "## 他のクレートの利用"
#. type: Plain text
-#: doc/rust.md:2442
+#: src/doc/rust.md:2447
#, fuzzy
#| msgid "## Operators"
msgid "#### Arithmetic operators"
msgstr "## 演算子"
#. type: Plain text
-#: doc/rust.md:2465
+#: src/doc/rust.md:2470
#, fuzzy
#| msgid "## Operators"
msgid "#### Bitwise operators"
msgstr "## 演算子"
#. type: Plain text
-#: doc/rust.md:2497
+#: src/doc/rust.md:2493
+#, fuzzy
+#| msgid "# Control structures"
+msgid "#### Lazy boolean operators"
+msgstr "# 制御構造"
+
+#. type: Plain text
+#: src/doc/rust.md:2502
#, fuzzy
#| msgid "# Control structures"
msgid "#### Comparison operators"
msgstr "# 制御構造"
#. type: Plain text
-#: doc/rust.md:2524
+#: src/doc/rust.md:2529
#, fuzzy
#| msgid "## Tuple structs"
msgid "#### Type cast expressions"
msgstr "## タプル構造体"
#. type: Plain text
-#: doc/rust.md:2557
+#: src/doc/rust.md:2540
+#, fuzzy
+#| msgid "## Syntax extensions"
+msgid "An example of an `as` expression:"
+msgstr "## 構文拡張"
+
+#. type: Plain text
+#: src/doc/rust.md:2553
+#, fuzzy
+#| msgid "## Operators"
+msgid "#### Assignment expressions"
+msgstr "## 演算子"
+
+#. type: Plain text
+#: src/doc/rust.md:2562
#, fuzzy
#| msgid "~~~~ let hi = \"hi\"; let mut count = 0;"
msgid "~~~~ # let mut x = 0; # let y = 0;"
" let mut count = 0;"
#. type: Plain text
-#: doc/rust.md:2571
+#: src/doc/rust.md:2567
+#, fuzzy
+#| msgid "# Control structures"
+msgid "#### Compound assignment expressions"
+msgstr "# 制御構造"
+
+#. type: Plain text
+#: src/doc/rust.md:2576
#, fuzzy
#| msgid "## Operators"
msgid "#### Operator precedence"
msgstr "## 演算子"
#. type: Plain text
-#: doc/rust.md:2611
+#: src/doc/rust.md:2599
+#, fuzzy
+#| msgid "## Tuples"
+msgid "### Grouped expressions"
+msgstr "## タプル"
+
+#. type: Plain text
+#: src/doc/rust.md:2609
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of a parenthesized expression:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:2613
+#, fuzzy
+#| msgid "~~~~ # let mystery_object = ();"
+msgid "~~~~ let x = (2 + 3) * 4; ~~~~"
+msgstr ""
+"~~~~\n"
+"# let mystery_object = ();"
+
+#. type: Plain text
+#: src/doc/rust.md:2616
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### Call expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2632
+#: src/doc/rust.md:2629
+#, fuzzy
+#| msgid "## Syntax extensions"
+msgid "Some examples of call expressions:"
+msgstr "## 構文拡張"
+
+#. type: Plain text
+#: src/doc/rust.md:2633
+#, fuzzy
+#| msgid ""
+#| "~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, "
+#| "b: int, x: int) -> () { a * x + b; }"
+msgid ""
+"~~~~ # use std::from_str::FromStr; # fn add(x: int, y: int) -> int { 0 }"
+msgstr ""
+"~~~~\n"
+"fn line(a: int, b: int, x: int) -> int { a * x + b }\n"
+"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+
+#. type: Plain text
+#: src/doc/rust.md:2637
#, fuzzy
#| msgid ""
#| "~~~~ let x: f64 = 4.0; let y: uint = x as uint; assert!(y == 4u); ~~~~"
"~~~~"
#. type: Plain text
-#: doc/rust.md:2634
+#: src/doc/rust.md:2639
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### Lambda expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2677
+#: src/doc/rust.md:2677
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"~~~~\n"
+"fn ten_times(f: |int|) {\n"
+" let mut i = 0;\n"
+" while i < 10 {\n"
+" f(i);\n"
+" i += 1;\n"
+" }\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/rust.md:2682
#, fuzzy
#| msgid "## Loops"
msgid "### While loops"
msgstr "## ループ"
#. type: Plain text
-#: doc/rust.md:2688
+#: src/doc/rust.md:2693
#, fuzzy
#| msgid "## A minimal example"
msgid "An example:"
msgstr "## 最小限の例"
#. type: Plain text
-#: doc/rust.md:2691
+#: src/doc/rust.md:2696
#, fuzzy
#| msgid "~~~~ let hi = \"hi\"; let mut count = 0;"
msgid "~~~~ let mut i = 0;"
" let mut count = 0;"
#. type: Plain text
-#: doc/rust.md:2699
+#: src/doc/rust.md:2702
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"while i < 10 {\n"
+" println!(\"hello\");\n"
+" i = i + 1;\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/rust.md:2704
#, fuzzy
#| msgid "## Loops"
msgid "### Infinite loops"
msgstr "## ループ"
#. type: Plain text
-#: doc/rust.md:2714
+#: src/doc/rust.md:2719
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### Break expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2727
+#: src/doc/rust.md:2732
#, fuzzy
#| msgid "# Control structures"
msgid "### Continue expressions"
msgstr "# 制御構造"
#. type: Plain text
-#: doc/rust.md:2746
-#, fuzzy
-#| msgid "## Conventions"
-msgid "### Do expressions"
-msgstr "## 本書の表記について"
-
-#. type: Plain text
-#: doc/rust.md:2792
+#: src/doc/rust.md:2751
#, fuzzy
#| msgid "## Freezing"
msgid "### For expressions"
msgstr "## 凍結"
#. type: Plain text
-#: doc/rust.md:2826
+#: src/doc/rust.md:2760
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of a for loop over the contents of a vector:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:2774
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"for e in v.iter() {\n"
+" bar(*e);\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/rust.md:2776
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of a for loop over a series of integers:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:2785
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### If expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2847
+#: src/doc/rust.md:2806
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### Match expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2940
+#: src/doc/rust.md:2885
+#, fuzzy
+#| msgid "## Syntax extensions"
+msgid "An example of a `match` expression:"
+msgstr "## 構文拡張"
+
+#. type: Plain text
+#: src/doc/rust.md:2935
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"fn main() {\n"
+" let a = Cons(6, ~Cons(7, ~Cons(42, ~Nil)));\n"
+" assert!(is_sorted(&a));\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/rust.md:2967
#, fuzzy
#| msgid "~~~~ # let mystery_object = ();"
msgid "~~~~ # let x = 2;"
"# let mystery_object = ();"
#. type: Plain text
-#: doc/rust.md:2970
+#: src/doc/rust.md:2997
#, fuzzy
#| msgid "## Syntax extensions"
msgid "### Return expressions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/rust.md:2994
+#: src/doc/rust.md:3008
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of a `return` expression:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:3017
+#, fuzzy, no-wrap
+#| msgid "~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+msgid ""
+"~~~~\n"
+"fn max(a: int, b: int) -> int {\n"
+" if a > b {\n"
+" return a;\n"
+" }\n"
+" return b;\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~\n"
+"fn line(a: int, b: int, x: int) -> int { a * x + b }\n"
+"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+
+#. type: Plain text
+#: src/doc/rust.md:3021
#, fuzzy
#| msgid "## Tuples"
msgid "## Types"
msgstr "## タプル"
#. type: Plain text
-#: doc/rust.md:3003
+#: src/doc/rust.md:3030
#, fuzzy
#| msgid "## Primitive types and literals"
msgid "### Primitive types"
msgstr "## プリミティブ型とリテラル"
#. type: Plain text
-#: doc/rust.md:3005
+#: src/doc/rust.md:3032
#, fuzzy
#| msgid "## Primitive types and literals"
msgid "The primitive types are the following:"
msgstr "## プリミティブ型とリテラル"
+#. type: Bullet: '* '
+#: src/doc/rust.md:3038
+#, fuzzy
+#| msgid "# Closures"
+msgid "The machine types."
+msgstr "# クロージャ"
+
+#. type: Bullet: '* '
+#: src/doc/rust.md:3038
+#, fuzzy
+#| msgid "# Closures"
+msgid "The machine-dependent integer and floating-point types."
+msgstr "# クロージャ"
+
#. type: Plain text
-#: doc/rust.md:3013
+#: src/doc/rust.md:3040
#, fuzzy
#| msgid "# Closures"
msgid "#### Machine types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3041
+#: src/doc/rust.md:3042
+#, fuzzy
+#| msgid "## Primitive types and literals"
+msgid "The machine types are the following:"
+msgstr "## プリミティブ型とリテラル"
+
+#. type: Plain text
+#: src/doc/rust.md:3056
+#, fuzzy
+#| msgid "# Closures"
+msgid "#### Machine-dependent integer types"
+msgstr "# クロージャ"
+
+#. type: Plain text
+#: src/doc/rust.md:3068
#, fuzzy
#| msgid "# Closures"
msgid "### Textual types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3054
+#: src/doc/rust.md:3081
#, fuzzy
#| msgid "## Tuples"
msgid "### Tuple types"
msgstr "## タプル"
#. type: Plain text
-#: doc/rust.md:3078
+#: src/doc/rust.md:3096
+#, fuzzy
+#| msgid "# Vectors and strings"
+msgid "An example of a tuple type and its use:"
+msgstr "# ベクタと文字列"
+
+#. type: Plain text
+#: src/doc/rust.md:3105
#, fuzzy
#| msgid "# Closures"
msgid "### Vector types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3102
+#: src/doc/rust.md:3123
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of a vector type and its use:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:3129
#, fuzzy
#| msgid ""
#| "~~~~ let x: f64 = 4.0; let y: uint = x as uint; assert!(y == 4u); ~~~~"
"~~~~"
#. type: Plain text
-#: doc/rust.md:3107
+#: src/doc/rust.md:3134
#, fuzzy
#| msgid "# Closures"
msgid "### Structure types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3128
+#: src/doc/rust.md:3156
#, fuzzy
#| msgid "# Closures"
msgid "### Enumerated types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3146
+#: src/doc/rust.md:3174
#, fuzzy
#| msgid "# Closures"
msgid "### Recursive types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3173
+#: src/doc/rust.md:3190
+#, fuzzy
+#| msgid "# Vectors and strings"
+msgid "An example of a *recursive* type and its use:"
+msgstr "# ベクタと文字列"
+
+#. type: Plain text
+#: src/doc/rust.md:3201
#, fuzzy
#| msgid "# Closures"
msgid "### Pointer types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3221
+#: src/doc/rust.md:3249
#, fuzzy
#| msgid "# Functions"
msgid "### Function types"
msgstr "# 関数"
#. type: Plain text
-#: doc/rust.md:3241
+#: src/doc/rust.md:3255
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of a `fn` type:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:3260
+#, fuzzy, no-wrap
+#| msgid "~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+msgid ""
+"~~~~\n"
+"fn add(x: int, y: int) -> int {\n"
+" return x + y;\n"
+"}\n"
+msgstr ""
+"~~~~\n"
+"fn line(a: int, b: int, x: int) -> int { a * x + b }\n"
+"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+
+#. type: Plain text
+#: src/doc/rust.md:3262
+#, fuzzy
+#| msgid "~~~~ let hi = \"hi\"; let mut count = 0;"
+msgid "let mut x = add(5,7);"
+msgstr ""
+"~~~~\n"
+" let hi = \"hi\";\n"
+" let mut count = 0;"
+
+#. type: Plain text
+#: src/doc/rust.md:3269
#, fuzzy
#| msgid "# Closures"
msgid "### Closure types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3251
+#: src/doc/rust.md:3274
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of creating and calling a closure:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:3279
#, fuzzy
#| msgid ""
#| "let captured_var = 20; let closure = |arg| println(fmt!(\"captured_var="
"arg));"
#. type: Plain text
-#: doc/rust.md:3256
+#: src/doc/rust.md:3284
#, fuzzy, no-wrap
#| msgid "let captured_var = 20; let closure = |arg| println(fmt!(\"captured_var=%d, arg=%d\", captured_var, arg));"
msgid ""
"let closure = |arg| println(fmt!(\"captured_var=%d, arg=%d\", captured_var, arg));"
#. type: Plain text
-#: doc/rust.md:3267
+#: src/doc/rust.md:3295
#, fuzzy
#| msgid "# Closures"
msgid "### Object types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3299
+#: src/doc/rust.md:3309
+#, fuzzy
+#| msgid "## A minimal example"
+msgid "An example of an object type:"
+msgstr "## 最小限の例"
+
+#. type: Plain text
+#: src/doc/rust.md:3314
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~~\n"
+"trait Printable {\n"
+" fn to_string(&self) -> ~str;\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/rust.md:3318
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"impl Printable for int {\n"
+" fn to_string(&self) -> ~str { self.to_str() }\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/rust.md:3327
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
msgid ""
"~~~~"
#. type: Plain text
-#: doc/rust.md:3322
+#: src/doc/rust.md:3332
+#, fuzzy
+#| msgid "## Tuples"
+msgid "### Type parameters"
+msgstr "## タプル"
+
+#. type: Plain text
+#: src/doc/rust.md:3350
#, fuzzy
#| msgid "# Closures"
msgid "### Self types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3343
+#: src/doc/rust.md:3359
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~~\n"
+"trait Printable {\n"
+" fn make_string(&self) -> ~str;\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/rust.md:3366
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"impl Printable for ~str {\n"
+" fn make_string(&self) -> ~str {\n"
+" (*self).clone()\n"
+" }\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/rust.md:3371
#, fuzzy
#| msgid "## Tuples"
msgid "## Type kinds"
msgstr "## タプル"
#. type: Plain text
-#: doc/rust.md:3440
+#: src/doc/rust.md:3429
+#, fuzzy
+#| msgid "## Managed boxes"
+msgid "# Memory and concurrency models"
+msgstr "## マネージドボックス"
+
+#. type: Plain text
+#: src/doc/rust.md:3441
+#, fuzzy
+#| msgid "## Managed boxes"
+msgid "## Memory model"
+msgstr "## マネージドボックス"
+
+#. type: Plain text
+#: src/doc/rust.md:3450
+#, fuzzy
+#| msgid "# Introduction"
+msgid "### Memory allocation and lifetime"
+msgstr "# イントロダクション"
+
+#. type: Plain text
+#: src/doc/rust.md:3468
#, fuzzy
#| msgid "# Ownership"
msgid "### Memory ownership"
msgstr "# 所有権"
#. type: Plain text
-#: doc/rust.md:3497
+#: src/doc/rust.md:3492
+#, fuzzy
+#| msgid "## Managed boxes"
+msgid "### Memory slots"
+msgstr "## マネージドボックス"
+
+#. type: Plain text
+#: src/doc/rust.md:3525
#, fuzzy
#| msgid "## Managed boxes"
msgid "### Memory boxes"
msgstr "## マネージドボックス"
#. type: Plain text
-#: doc/rust.md:3519
+#: src/doc/rust.md:3547
#, fuzzy
#| msgid "~~~~ let hi = \"hi\"; let mut count = 0;"
msgid "~~~~ let x: @int = @10; let x: ~int = ~10; ~~~~"
" let mut count = 0;"
#. type: Plain text
-#: doc/rust.md:3555
+#: src/doc/rust.md:3556
+#, fuzzy
+#| msgid ""
+#| "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: "
+#| "20f }; println(fmt!(\"%f\", point.x)); ~~~"
+msgid ""
+"~~~~ struct Foo { y: int } let x = @Foo{y: 10}; assert!(x.y == 10); ~~~~"
+msgstr ""
+"~~~\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let point = &@~Point { x: 10f, y: 20f };\n"
+"println(fmt!(\"%f\", point.x));\n"
+"~~~"
+
+#. type: Plain text
+#: src/doc/rust.md:3581
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"fn main() {\n"
+" let x: @int = @10;\n"
+" takes_boxed(x);\n"
+" takes_unboxed(*x);\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/rust.md:3583
#, fuzzy
#| msgid "## Traits"
msgid "## Tasks"
msgstr "## トレイト"
#. type: Plain text
-#: doc/rust.md:3580
+#: src/doc/rust.md:3608
#, fuzzy
#| msgid "## Conditionals"
msgid "### Communication between tasks"
msgstr "## 条件式"
#. type: Plain text
-#: doc/rust.md:3660
+#: src/doc/rust.md:3668
+#, fuzzy
+#| msgid "[Tasks and communication][tasks]"
+msgid "### Task scheduling"
+msgstr "[タスクと通信][tasks]"
+
+#. type: Plain text
+#: src/doc/rust.md:3688
#, fuzzy
#| msgid "# Introduction"
msgid "### Memory allocation"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/rust.md:3672
+#: src/doc/rust.md:3700
#, fuzzy
#| msgid "# Closures"
msgid "### Built in types"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/rust.md:3681
+#: src/doc/rust.md:3709
#, fuzzy
#| msgid "[Tasks and communication][tasks]"
msgid "### Task scheduling and communication"
msgstr "[タスクと通信][tasks]"
#. type: Plain text
-#: doc/rust.md:3689
+#: src/doc/rust.md:3717
#, fuzzy
#| msgid "## Freezing"
msgid "### Linkage"
msgstr "## 凍結"
#. type: Plain text
-#: doc/rust.md:3861
+#: src/doc/rust.md:3822
+#, fuzzy
+#| msgid "## Freezing"
+msgid "### Logging system"
+msgstr "## 凍結"
+
+#. type: Plain text
+#: src/doc/rust.md:3860
+#, fuzzy
+#| msgid "## Conventions"
+msgid "#### Logging Expressions"
+msgstr "## 本書の表記について"
+
+#. type: Plain text
+#: src/doc/rust.md:3889
#, fuzzy
msgid "## Influences"
msgstr "# ポインタのデリファレンス"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.10-pre\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2014-01-13 12:01+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/rustdoc.md:2
+#: src/doc/rustdoc.md:2
#, fuzzy
#| msgid "## Using the rust tool"
msgid "% Rust Documentation"
msgstr "## `rust` コマンドを利用する"
#. type: Plain text
-#: doc/rustdoc.md:9
+#: src/doc/rustdoc.md:9
#, fuzzy
#| msgid "## Using the rust tool"
msgid "# Creating Documentation"
msgstr "## `rust` コマンドを利用する"
#. type: Plain text
-#: doc/rustdoc.md:79
+#: src/doc/rustdoc.md:79
#, fuzzy
#| msgid "## Using the rust tool"
msgid "# Using the Documentation"
msgstr "## `rust` コマンドを利用する"
#. type: Plain text
-#: doc/rustdoc.md:90
+#: src/doc/rustdoc.md:90
#, fuzzy
#| msgid "## Using the rust tool"
msgid "# Testing the Documentation"
msgstr "## `rust` コマンドを利用する"
#. type: Plain text
-#: doc/rustdoc.md:102
+#: src/doc/rustdoc.md:102
#, fuzzy
#| msgid "# Dereferencing pointers"
msgid "## Defining tests"
msgstr "# ポインタのデリファレンス"
+
+#. type: Plain text
+#: src/doc/rustdoc.md:159
+#, fuzzy
+#| msgid "# Dereferencing pointers"
+msgid "## Running tests (advanced)"
+msgstr "# ポインタのデリファレンス"
+++ /dev/null
-# Japanese translations for Rust package
-# Copyright (C) 2013 The Rust Project Developers
-# This file is distributed under the same license as the Rust package.
-# Automatically generated, 2013.
-#
-msgid ""
-msgstr ""
-"Project-Id-Version: Rust 0.8\n"
-"POT-Creation-Date: 2014-01-13 12:01+0900\n"
-"PO-Revision-Date: 2013-07-28 20:32+0900\n"
-"Last-Translator: Automatically generated\n"
-"Language-Team: none\n"
-"Language: ja\n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=1; plural=0;\n"
-
-#. type: Plain text
-#: doc/guide-conditions.md:4 doc/guide-ffi.md:4 doc/guide-lifetimes.md:4
-#: doc/guide-macros.md:4 doc/guide-rustpkg.md:4 doc/guide-tasks.md:4
-#: doc/rust.md:4 doc/rustpkg.md:4 doc/tutorial.md:4
-msgid "# Introduction"
-msgstr "# イントロダクション"
-
-#. type: Plain text
-#: doc/rustpkg.md:2
-#, fuzzy
-#| msgid "% The Rust Language Tutorial"
-msgid "% Rustpkg Reference Manual"
-msgstr "% Rust 言語チュートリアル"
-
-#. type: Plain text
-#: doc/rustpkg.md:14
-#, fuzzy
-#| msgid "## Pattern matching"
-msgid "# Package searching"
-msgstr "## パターンマッチ"
-
-#. type: Plain text
-#: doc/rustpkg.md:40
-#, fuzzy
-#| msgid "# Data structures"
-msgid "# Package structure"
-msgstr "# データ構造"
-
-#. type: Plain text
-#: doc/rustpkg.md:106
-#, fuzzy
-#| msgid "## Conventions"
-msgid "## Versions"
-msgstr "## 本書の表記について"
-
-#. type: Plain text
-#: doc/rustpkg.md:133
-#, fuzzy
-msgid "# Command reference"
-msgstr "# ポインタのデリファレンス"
-
-#. type: Plain text
-#: doc/rustpkg.md:150
-#, fuzzy
-#| msgid "# Introduction"
-msgid "## install"
-msgstr "# イントロダクション"
msgid ""
msgstr ""
"Project-Id-Version: Rust 0.8\n"
-"POT-Creation-Date: 2014-01-14 21:02+0900\n"
+"POT-Creation-Date: 2014-02-03 08:13+0900\n"
"PO-Revision-Date: 2013-08-08 22:27+0900\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. type: Plain text
-#: doc/guide-conditions.md:4 doc/guide-ffi.md:4 doc/guide-lifetimes.md:4
-#: doc/guide-macros.md:4 doc/guide-rustpkg.md:4 doc/guide-tasks.md:4
-#: doc/rust.md:4 doc/rustpkg.md:4 doc/tutorial.md:4
+#: src/doc/guide-conditions.md:4 src/doc/guide-ffi.md:4
+#: src/doc/guide-lifetimes.md:4 src/doc/guide-macros.md:4
+#: src/doc/guide-tasks.md:4 src/doc/rust.md:4 src/doc/tutorial.md:4
msgid "# Introduction"
msgstr "# イントロダクション"
#. type: Plain text
-#: doc/guide-ffi.md:168 doc/tutorial.md:875
+#: src/doc/guide-ffi.md:168 src/doc/tutorial.md:885
msgid "# Destructors"
msgstr "# デストラクタ"
#. type: Plain text
-#: doc/guide-lifetimes.md:72 doc/tutorial.md:1394
+#: src/doc/guide-lifetimes.md:72 src/doc/tutorial.md:1409
msgid "Now we can call `compute_distance()` in various ways:"
msgstr ""
"上記の `compute_distance()` 関数は、様々な方法で呼び出すことができます。"
#. type: Plain text
-#: doc/guide-pointers.md:326 doc/tutorial.md:1345
+#: src/doc/guide-pointers.md:326 src/doc/tutorial.md:1360
#, fuzzy
msgid "# References"
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/guide-testing.md:127 doc/tutorial.md:776
+#: src/doc/guide-testing.md:127 src/doc/tutorial.md:786
#, fuzzy
-#| msgid "## A minimal example"
msgid "For example:"
msgstr "## 最小限の例"
#. type: Plain text
-#: doc/rust.md:1388 doc/tutorial.md:2508
+#: src/doc/rust.md:1391 src/doc/tutorial.md:2495
msgid "Likewise, supertrait methods may also be called on trait objects."
msgstr ""
"同様に、スーパートレイトのメソッドは、トレイトオブジェクトについても呼び出す"
"ことが可能です。"
#. type: Plain text
-#: doc/tutorial.md:2
+#: src/doc/tutorial.md:2
msgid "% The Rust Language Tutorial"
msgstr "% Rust 言語チュートリアル"
#. type: Plain text
-#: doc/tutorial.md:13
+#: src/doc/tutorial.md:13
msgid ""
"Rust is a programming language with a focus on type safety, memory safety, "
"concurrency and performance. It is intended for writing large-scale, high-"
"的型付けされた、コンパイル型の言語です。"
#. type: Plain text
-#: doc/tutorial.md:17
+#: src/doc/tutorial.md:17
msgid ""
"As a multi-paradigm language, Rust supports writing code in procedural, "
"functional and object-oriented styles. Some of its pleasant high-level "
"す。"
#. type: Bullet: '* '
-#: doc/tutorial.md:30
+#: src/doc/tutorial.md:30
msgid ""
"**Type inference.** Type annotations on local variable declarations are "
"optional."
"**型推論:** ローカル変数の宣言では型注釈 (type annotation) を省略できます。"
#. type: Bullet: '* '
-#: doc/tutorial.md:30
+#: src/doc/tutorial.md:30
msgid ""
"**Safe task-based concurrency.** Rust's lightweight tasks do not share "
"memory, instead communicating through messages."
"るのではなく、メッセージを介して通信します。"
#. type: Bullet: '* '
-#: doc/tutorial.md:30
+#: src/doc/tutorial.md:30
msgid ""
"**Higher-order functions.** Efficient and flexible closures provide "
"iteration and other control structures"
"造を実現できます。"
#. type: Bullet: '* '
-#: doc/tutorial.md:30
+#: src/doc/tutorial.md:30
msgid ""
"**Pattern matching and algebraic data types.** Pattern matching on Rust's "
"enumeration types (a more powerful version of C's enums, similar to "
"ログラムの論理を、コンパクトで表現力豊かに記述することができます。"
#. type: Bullet: '* '
-#: doc/tutorial.md:30
+#: src/doc/tutorial.md:30
msgid ""
"**Polymorphism.** Rust has type-parametric functions and types, type classes "
"and OO-style interfaces."
"ジェクト指向風のインターフェースがあります。"
#. type: Plain text
-#: doc/tutorial.md:32
+#: src/doc/tutorial.md:32
msgid "## Scope"
msgstr "## 本文書の位置づけ"
#. type: Plain text
-#: doc/tutorial.md:38
+#: src/doc/tutorial.md:38
msgid ""
"This is an introductory tutorial for the Rust programming language. It "
"covers the fundamentals of the language, including the syntax, the type "
"テップは) を参照してください。"
#. type: Plain text
-#: doc/tutorial.md:42
+#: src/doc/tutorial.md:42
msgid ""
"This tutorial assumes that the reader is already familiar with one or more "
"languages in the C family. Understanding of pointers and general memory "
"知識が役に立つでしょう。"
#. type: Plain text
-#: doc/tutorial.md:44
+#: src/doc/tutorial.md:44
msgid "## Conventions"
msgstr "## 本書の表記について"
#. type: Plain text
-#: doc/tutorial.md:47
+#: src/doc/tutorial.md:47
msgid ""
"Throughout the tutorial, language keywords and identifiers defined in "
"example code are displayed in `code font`."
"を `code font` のように示します。"
#. type: Plain text
-#: doc/tutorial.md:53
+#: src/doc/tutorial.md:53
msgid ""
"Code snippets are indented, and also shown in a monospaced font. Not all "
"snippets constitute whole programs. For brevity, we'll often show fragments "
"ださい。"
#. type: Plain text
-#: doc/tutorial.md:57
+#: src/doc/tutorial.md:57
msgid ""
"> ***Warning:*** Rust is a language under ongoing development. Notes > about "
"potential changes to the language, implementation > deficiencies, and other "
"注意してください。"
#. type: Plain text
-#: doc/tutorial.md:59
+#: src/doc/tutorial.md:59
msgid "# Getting started"
msgstr "# はじめに"
#. type: Plain text
-#: doc/tutorial.md:67
+#: src/doc/tutorial.md:67
#, fuzzy
#| msgid ""
#| "The Rust compiler currently must be built from a [tarball], unless you "
"トーラー][win-exe] の使用をおすすめします。"
#. type: Plain text
-#: doc/tutorial.md:72
+#: src/doc/tutorial.md:72
#, fuzzy
#| msgid ""
#| "Since the Rust compiler is written in Rust, it must be built by a "
"す。"
#. type: Plain text
-#: doc/tutorial.md:74
+#: src/doc/tutorial.md:74
msgid "Snapshot binaries are currently built and tested on several platforms:"
msgstr ""
"スナップショットバイナリは、現時点では以下のプラットフォーム向けのものがあり"
"ます。"
#. type: Bullet: '* '
-#: doc/tutorial.md:78
-msgid "Windows (7, Server 2008 R2), x86 only"
+#: src/doc/tutorial.md:78
+#, fuzzy
+#| msgid "Windows (7, Server 2008 R2), x86 only"
+msgid "Windows (7, 8, Server 2008 R2), x86 only"
msgstr "Windows (7, Server 2008 R2), x86 のみ"
#. type: Bullet: '* '
-#: doc/tutorial.md:78
-msgid "Linux (various distributions), x86 and x86-64"
+#: src/doc/tutorial.md:78
+#, fuzzy
+#| msgid "Linux (various distributions), x86 and x86-64"
+msgid "Linux (2.6.18 or later, various distributions), x86 and x86-64"
msgstr "Linux (各種ディストリビューション), x86 または x86-64"
#. type: Bullet: '* '
-#: doc/tutorial.md:78
-msgid "OSX 10.6 (\"Snow Leopard\") or greater, x86 and x86-64"
+#: src/doc/tutorial.md:78
+#, fuzzy
+#| msgid "OSX 10.6 (\"Snow Leopard\") or greater, x86 and x86-64"
+msgid "OSX 10.7 (Lion) or greater, x86 and x86-64"
msgstr "OSX 10.6 (\"Snow Leopard\") 以降, x86 または x86-64"
#. type: Plain text
-#: doc/tutorial.md:81
+#: src/doc/tutorial.md:81
msgid ""
"You may find that other platforms work, but these are our \"tier 1\" "
"supported build environments that are most likely to work."
"1\" プラットフォームとしてサポートされているのは上記のみです。"
#. type: Plain text
-#: doc/tutorial.md:88
+#: src/doc/tutorial.md:88
msgid ""
"> ***Note:*** Windows users should read the detailed > \"[getting started]"
"[wiki-start]\" notes on the wiki. Even when using > the binary installer, "
"ません。このような制限があることはは、本当に残念です。"
#. type: Plain text
-#: doc/tutorial.md:92
+#: src/doc/tutorial.md:92
#, fuzzy
#| msgid ""
#| "[bug-3319]: https://github.com/mozilla/rust/issues/3319 [wiki-start]: "
"developing-Rust"
#. type: Plain text
-#: doc/tutorial.md:95
+#: src/doc/tutorial.md:95
msgid ""
"To build from source you will also need the following prerequisite packages:"
msgstr "ソースからビルドするためには、以下のパッケージが必要です。"
#. type: Bullet: '* '
-#: doc/tutorial.md:101
+#: src/doc/tutorial.md:101
msgid "g++ 4.4 or clang++ 3.x"
msgstr "g++ 4.4 または clang++ 3.x"
#. type: Bullet: '* '
-#: doc/tutorial.md:101
+#: src/doc/tutorial.md:101
msgid "python 2.6 or later (but not 3.x)"
msgstr "python 2.6 以降 (ただし、 3.x は除く)"
#. type: Bullet: '* '
-#: doc/tutorial.md:101
+#: src/doc/tutorial.md:101
msgid "perl 5.0 or later"
msgstr "perl 5.0 以降"
#. type: Bullet: '* '
-#: doc/tutorial.md:101
+#: src/doc/tutorial.md:101
msgid "gnu make 3.81 or later"
msgstr "gnu make 3.81 以降"
#. type: Bullet: '* '
-#: doc/tutorial.md:101
+#: src/doc/tutorial.md:101
msgid "curl"
msgstr "curl"
#. type: Plain text
-#: doc/tutorial.md:104
+#: src/doc/tutorial.md:104
msgid ""
"If you've fulfilled those prerequisites, something along these lines should "
"work."
msgstr "上記条件を満たしていれば、以下のような手順でビルド可能なはずです。"
#. type: Plain text
-#: doc/tutorial.md:112
+#: src/doc/tutorial.md:112
#, fuzzy
#| msgid ""
#| "~~~~ {.notrust} $ curl -O http://static.rust-lang.org/dist/rust-0.7.tar."
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:118
+#: src/doc/tutorial.md:118
msgid ""
"You may need to use `sudo make install` if you do not normally have "
"permission to modify the destination directory. The install locations can be "
"ポートしています。詳細については、 `--help` 引数を指定して実行してください。"
#. type: Plain text
-#: doc/tutorial.md:122
+#: src/doc/tutorial.md:122
+#, fuzzy
+#| msgid ""
+#| "When complete, `make install` will place several programs into `/usr/"
+#| "local/bin`: `rustc`, the Rust compiler; `rustdoc`, the API-documentation "
+#| "tool; and `rustpkg`, the Rust package manager."
msgid ""
"When complete, `make install` will place several programs into `/usr/local/"
-"bin`: `rustc`, the Rust compiler; `rustdoc`, the API-documentation tool; and "
-"`rustpkg`, the Rust package manager."
+"bin`: `rustc`, the Rust compiler, and `rustdoc`, the API-documentation tool."
msgstr ""
"ビルド完了後、`make install` を実行すると、以下のプログラムが `/usr/local/"
"bin` にインストールされます。\n"
"* `rustpkg`: Rust のパッケージマネージャ\n"
#. type: Plain text
-#: doc/tutorial.md:125
+#: src/doc/tutorial.md:125
#, fuzzy
#| msgid ""
#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
#. type: Plain text
-#: doc/tutorial.md:127
+#: src/doc/tutorial.md:127
msgid "## Compiling your first program"
msgstr "## 最初のプログラム"
#. type: Plain text
-#: doc/tutorial.md:130
+#: src/doc/tutorial.md:130
msgid ""
"Rust program files are, by convention, given the extension `.rs`. Say we "
"have a file `hello.rs` containing this program:"
"容を持つファイル、`hello.rs` が存在するとします。"
#. type: Plain text
-#: doc/tutorial.md:136
+#: src/doc/tutorial.md:136
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
msgid ""
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:140
+#: src/doc/tutorial.md:140
msgid ""
"If the Rust compiler was installed successfully, running `rustc hello.rs` "
"will produce an executable called `hello` (or `hello.exe` on Windows) which, "
"が可能です。このファイルを実行すれば、予想通りの出力が得られるでしょう。"
#. type: Plain text
-#: doc/tutorial.md:145
+#: src/doc/tutorial.md:145
#, fuzzy
#| msgid ""
#| "The Rust compiler tries to provide useful information when it encounters "
"が出力されます。"
#. type: Plain text
-#: doc/tutorial.md:158
+#: src/doc/tutorial.md:158
#, fuzzy
#| msgid ""
#| "In its simplest form, a Rust program is a `.rs` file with some types and "
"プログラムから利用するライブラリとしてコンパイルすることも可能です。"
#. type: Plain text
-#: doc/tutorial.md:160
+#: src/doc/tutorial.md:160
msgid "## Editing Rust code"
msgstr "## Rust のコードを編集する"
#. type: Plain text
-#: doc/tutorial.md:170
+#: src/doc/tutorial.md:170
msgid ""
"There are vim highlighting and indentation scripts in the Rust source "
"distribution under `src/etc/vim/`. There is an emacs mode under `src/etc/"
"etc/kate` 以下です。"
#. type: Plain text
-#: doc/tutorial.md:177
+#: src/doc/tutorial.md:177
msgid ""
"There is ctags support via `src/etc/ctags.rust`, but many other tools and "
"editors are not yet supported. If you end up writing a Rust mode for your "
"ディタ向けのRust モードを作成した場合、リンクを貼りたいのでお知らせください。"
#. type: Plain text
-#: doc/tutorial.md:180
+#: src/doc/tutorial.md:180
msgid ""
"[sublime]: http://github.com/dbp/sublime-rust [sublime-pkg]: http://wbond."
"net/sublime_packages/package_control"
"[sublime-pkg]: http://wbond.net/sublime_packages/package_control"
#. type: Plain text
-#: doc/tutorial.md:182
+#: src/doc/tutorial.md:182
msgid "# Syntax basics"
msgstr "# 基本的な構文"
#. type: Plain text
-#: doc/tutorial.md:190
+#: src/doc/tutorial.md:190
msgid ""
"Assuming you've programmed in any C-family language (C++, Java, JavaScript, "
"C#, or PHP), Rust will feel familiar. Code is arranged in blocks delineated "
"レータは C++ と同様 2つのコロン (`::`) です。"
#. type: Plain text
-#: doc/tutorial.md:195
+#: src/doc/tutorial.md:195
msgid ""
"The main surface difference to be aware of is that the condition at the head "
"of control structures like `if` and `while` does not require parentheses, "
"とはできません。"
#. type: Plain text
-#: doc/tutorial.md:208
+#: src/doc/tutorial.md:208
#, no-wrap
msgid ""
"~~~~\n"
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:212
+#: src/doc/tutorial.md:212
msgid ""
"The `let` keyword introduces a local variable. Variables are immutable by "
"default. To introduce a local variable that you can re-assign later, use "
"mut` を用います。"
#. type: Plain text
-#: doc/tutorial.md:216
+#: src/doc/tutorial.md:216
msgid "~~~~ let hi = \"hi\"; let mut count = 0;"
msgstr ""
"~~~~\n"
" let mut count = 0;"
#. type: Plain text
-#: doc/tutorial.md:226
+#: src/doc/tutorial.md:222
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"while count < 10 {\n"
+" println!(\"count is {}\", count);\n"
+" count += 1;\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:226
#, fuzzy
#| msgid ""
#| "Although Rust can almost always infer the types of local variables, you "
"(static item) には、常に型注釈を指定しなければなりません。"
#. type: Plain text
-#: doc/tutorial.md:233
+#: src/doc/tutorial.md:233
msgid ""
"~~~~ static MONSTER_FACTOR: f64 = 57.8; let monster_size = MONSTER_FACTOR * "
"10.0; let monster_size: int = 50; ~~~~"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:242
+#: src/doc/tutorial.md:242
msgid ""
"Local variables may shadow earlier declarations, as in the previous example: "
"`monster_size` was first declared as a `f64`, and then a second "
"ます (`let _monster_size = 50;`)。"
#. type: Plain text
-#: doc/tutorial.md:248
+#: src/doc/tutorial.md:248
msgid ""
"Rust identifiers start with an alphabetic character or an underscore, and "
"after that may contain any sequence of alphabetic characters, numbers, or "
"されています。"
#. type: Plain text
-#: doc/tutorial.md:253
+#: src/doc/tutorial.md:253
#, no-wrap
msgid ""
"~~~\n"
"~~~\n"
#. type: Plain text
-#: doc/tutorial.md:255
+#: src/doc/tutorial.md:255
msgid "## Expressions and semicolons"
msgstr "## 式とセミコロン"
#. type: Plain text
-#: doc/tutorial.md:261
+#: src/doc/tutorial.md:261
msgid ""
"Though it isn't apparent in all code, there is a fundamental difference "
"between Rust's syntax and predecessors like C. Many constructs that are "
"ようにコードを書きますが、"
#. type: Plain text
-#: doc/tutorial.md:275
+#: src/doc/tutorial.md:275
msgid "But, in Rust, you don't have to repeat the name `price`:"
msgstr "Rust では、変数名 `price` を繰り返し書く必要はありません。"
#. type: Plain text
-#: doc/tutorial.md:293
+#: src/doc/tutorial.md:293
msgid ""
"Both pieces of code are exactly equivalent: they assign a value to `price` "
"depending on the condition that holds. Note that there are no semicolons in "
"最後の式の値になります**。"
#. type: Plain text
-#: doc/tutorial.md:299
+#: src/doc/tutorial.md:299
msgid ""
"Put another way, the semicolon in Rust *ignores the value of an "
"expression*. Thus, if the branches of the `if` had looked like `{ 4; }`, "
"には節のうち実行されたものの値が代入されます。"
#. type: Plain text
-#: doc/tutorial.md:304
+#: src/doc/tutorial.md:304
msgid ""
"In short, everything that's not a declaration (declarations are `let` for "
"variables; `fn` for functions; and any top-level named items such as [traits]"
"すべてが式となります。関数のボディ部も式です。"
#. type: Plain text
-#: doc/tutorial.md:312
+#: src/doc/tutorial.md:312
#, no-wrap
msgid ""
"~~~~\n"
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:314
+#: src/doc/tutorial.md:314
msgid "## Primitive types and literals"
msgstr "## プリミティブ型とリテラル"
#. type: Plain text
-#: doc/tutorial.md:321
+#: src/doc/tutorial.md:321
msgid ""
"There are general signed and unsigned integer types, `int` and `uint`, as "
"well as 8-, 16-, 32-, and 64-bit variants, `i8`, `u16`, etc. Integers can "
"応します。"
#. type: Plain text
-#: doc/tutorial.md:327
+#: src/doc/tutorial.md:327
msgid ""
"In the absence of an integer literal suffix, Rust will infer the integer "
"type based on type annotations and function signatures in the surrounding "
"フィックスなしの整数リテラルは `int` 型だとみなされます。"
#. type: Plain text
-#: doc/tutorial.md:334
-#, no-wrap
+#: src/doc/tutorial.md:334
+#, fuzzy, no-wrap
+#| msgid ""
+#| "~~~~\n"
+#| "let a = 1; // a is an int\n"
+#| "let b = 10i; // b is an int, due to the 'i' suffix\n"
+#| "let c = 100u; // c is a uint\n"
+#| "let d = 1000i32; // d is an i32\n"
+#| "~~~~\n"
msgid ""
"~~~~\n"
-"let a = 1; // a is an int\n"
-"let b = 10i; // b is an int, due to the 'i' suffix\n"
-"let c = 100u; // c is a uint\n"
-"let d = 1000i32; // d is an i32\n"
+"let a = 1; // `a` is an `int`\n"
+"let b = 10i; // `b` is an `int`, due to the `i` suffix\n"
+"let c = 100u; // `c` is a `uint`\n"
+"let d = 1000i32; // `d` is an `i32`\n"
"~~~~\n"
msgstr ""
"~~~~\n"
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:339
+#: src/doc/tutorial.md:339
#, fuzzy
#| msgid ""
#| "There are two floating-point types: `f32`, and `f64`. Floating-point "
"す。"
#. type: Plain text
-#: doc/tutorial.md:341
+#: src/doc/tutorial.md:341
msgid "The keywords `true` and `false` produce literals of type `bool`."
msgstr "`true` キーワードと `false` キーワードは、`bool` 型のリテラルです。"
#. type: Plain text
-#: doc/tutorial.md:348
+#: src/doc/tutorial.md:348
#, fuzzy
#| msgid ""
#| "Characters, the `char` type, are four-byte Unicode codepoints, whose "
"タと文字列) の章で述べます。"
#. type: Plain text
-#: doc/tutorial.md:356
+#: src/doc/tutorial.md:356
msgid "The nil type, written `()`, has a single value, also written `()`."
msgstr ""
"nil 型は `()` と表記されます。 nil 型の唯一の値も `()` と表記されます。"
#. type: Plain text
-#: doc/tutorial.md:358
+#: src/doc/tutorial.md:358
msgid "## Operators"
msgstr "## 演算子"
#. type: Plain text
-#: doc/tutorial.md:363
+#: src/doc/tutorial.md:363
msgid ""
"Rust's set of operators contains very few surprises. Arithmetic is done with "
"`*`, `/`, `%`, `+`, and `-` (multiply, quotient, remainder, add, and "
"ポートされています。"
#. type: Plain text
-#: doc/tutorial.md:366
+#: src/doc/tutorial.md:366
#, fuzzy
#| msgid ""
#| "Note that, if applied to an integer value, `!` flips all the bits (like "
"じ動作) が行われることに注意してください。"
#. type: Plain text
-#: doc/tutorial.md:370
+#: src/doc/tutorial.md:370
msgid ""
"The comparison operators are the traditional `==`, `!=`, `<`, `>`, `<=`, and "
"`>=`. Short-circuiting (lazy) boolean operators are written `&&` (and) and "
"ります。"
#. type: Plain text
-#: doc/tutorial.md:377
+#: src/doc/tutorial.md:377
#, fuzzy
#| msgid ""
#| "For type casting, Rust uses the binary `as` operator. It takes an "
"た型に変換します。"
#. type: Plain text
-#: doc/tutorial.md:383
+#: src/doc/tutorial.md:383
msgid "~~~~ let x: f64 = 4.0; let y: uint = x as uint; assert!(y == 4u); ~~~~"
msgstr ""
"~~~~\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:385
+#: src/doc/tutorial.md:385
#, fuzzy
#| msgid ""
#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
#. type: Plain text
-#: doc/tutorial.md:387
+#: src/doc/tutorial.md:387
msgid "## Syntax extensions"
msgstr "## 構文拡張"
#. type: Plain text
-#: doc/tutorial.md:395
+#: src/doc/tutorial.md:395
#, fuzzy, no-wrap
#| msgid ""
#| "*Syntax extensions* are special forms that are not built into the language,\n"
msgstr "**構文拡張** *(Syntax extensions)* は言語組み込みではなく、ライブラリにより提供される特殊形式 (スペシャルフォーム) です。プログラム中に構文拡張が登場したことを外見上明確にするため、構文拡張の名前には末尾に `!` をつけますなければなりません。標準ライブラリではいくつかの構文拡張が定義されていますが、その中でも最も有用なのは `fmt!` です。`fmt!` は `sprintf`スタイルの書式整形を行うもので、後のコード例の中でも何度か見かけることになるでしょう。\n"
#. type: Plain text
-#: doc/tutorial.md:399
+#: src/doc/tutorial.md:399
#, fuzzy
#| msgid ""
#| "`fmt!` supports most of the directives that [printf][pf] supports, but "
"一致しない場合はコンパイルエラーとなります。"
#. type: Plain text
-#: doc/tutorial.md:402
+#: src/doc/tutorial.md:402
msgid "~~~~ # let mystery_object = ();"
msgstr ""
"~~~~\n"
"# let mystery_object = ();"
#. type: Plain text
-#: doc/tutorial.md:409
+#: src/doc/tutorial.md:409
#, fuzzy
#| msgid ""
#| "// %? will conveniently print any type println(fmt!(\"what is this thing: "
#| "%?\", mystery_object)); ~~~~"
msgid ""
-"// {:?} will conveniently print any type println!(\"what is this thing: "
+"// `{:?}` will conveniently print any type println!(\"what is this thing: "
"{:?}\", mystery_object); ~~~~"
msgstr ""
"// %? は任意の型を表示できる便利なディレクティブです\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:412
+#: src/doc/tutorial.md:412
#, fuzzy
#| msgid ""
#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
#. type: Plain text
-#: doc/tutorial.md:416
+#: src/doc/tutorial.md:416
#, fuzzy
#| msgid ""
#| "You can define your own syntax extensions with the macro system. For "
"[マクロチュートリアル][macros] を参照してください。"
#. type: Plain text
-#: doc/tutorial.md:418
+#: src/doc/tutorial.md:418
msgid "# Control structures"
msgstr "# 制御構造"
#. type: Plain text
-#: doc/tutorial.md:420
+#: src/doc/tutorial.md:420
msgid "## Conditionals"
msgstr "## 条件式"
#. type: Plain text
-#: doc/tutorial.md:424
+#: src/doc/tutorial.md:424
msgid ""
"We've seen `if` expressions a few times already. To recap, braces are "
"compulsory, an `if` can have an optional `else` clause, and multiple `if`/"
"構文は互いに連鎖できる、ということでした。"
#. type: Plain text
-#: doc/tutorial.md:439
+#: src/doc/tutorial.md:439
msgid ""
"The condition given to an `if` construct *must* be of type `bool` (no "
"implicit conversion happens). If the arms are blocks that have a value, this "
"るものは、すべて同じ型の値でなければなりません。"
#. type: Plain text
-#: doc/tutorial.md:449
+#: src/doc/tutorial.md:447
+#, fuzzy, no-wrap
+#| msgid "~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+msgid ""
+"~~~~\n"
+"fn signum(x: int) -> int {\n"
+" if x < 0 { -1 }\n"
+" else if x > 0 { 1 }\n"
+" else { 0 }\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~\n"
+"fn line(a: int, b: int, x: int) -> int { a * x + b }\n"
+"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
+
+#. type: Plain text
+#: src/doc/tutorial.md:449
msgid "## Pattern matching"
msgstr "## パターンマッチ"
#. type: Plain text
-#: doc/tutorial.md:455
+#: src/doc/tutorial.md:455
msgid ""
"Rust's `match` construct is a generalized, cleaned-up version of C's "
"`switch` construct. You provide it with a value and a number of *arms*, each "
"ターンとの比較は行われません。"
#. type: Plain text
-#: doc/tutorial.md:469
+#: src/doc/tutorial.md:469
msgid ""
"Unlike in C, there is no \"falling through\" between arms: only one arm "
"executes, and it doesn't have to explicitly `break` out of the construct "
"する必要はありません。"
#. type: Plain text
-#: doc/tutorial.md:478
+#: src/doc/tutorial.md:478
#, fuzzy
#| msgid ""
#| "A `match` arm consists of a *pattern*, then an arrow `=>`, followed by an "
"す)。"
#. type: Plain text
-#: doc/tutorial.md:483
+#: src/doc/tutorial.md:483
msgid ""
"The patterns in a match arm are followed by a fat arrow, `=>`, then an "
"expression to evaluate. Each case is separated by commas. It's often "
"を記述することも可能で、その場合は arm 末尾のカンマを省略することが可能です。"
#. type: Plain text
-#: doc/tutorial.md:496
+#: src/doc/tutorial.md:496
msgid ""
"`match` constructs must be *exhaustive*: they must have an arm covering "
"every possible case. For example, the typechecker would reject the previous "
"ンの arm を削除した場合、型検査によりコンパイルエラーとされます。"
#. type: Plain text
-#: doc/tutorial.md:500
+#: src/doc/tutorial.md:500
msgid ""
"A powerful application of pattern matching is *destructuring*: matching in "
"order to bind names to the contents of data types."
"造化代入とは、データ型内部の値を名前に束縛 (bind) することです。"
#. type: Plain text
-#: doc/tutorial.md:504
+#: src/doc/tutorial.md:504
msgid ""
"> ***Note:*** The following code makes use of tuples (`(f64, f64)`) which > "
"are explained in section 5.3. For now you can think of tuples as a list of > "
"い。"
#. type: Plain text
-#: doc/tutorial.md:523
+#: src/doc/tutorial.md:525
#, fuzzy
#| msgid ""
#| "A variable name in a pattern matches any value, *and* binds that name to "
"value of the matched value inside of the arm's action. Thus, `(0.0, y)` "
"matches any tuple whose first element is zero, and binds `y` to the second "
"element. `(x, y)` matches any two-element tuple, and binds both elements to "
-"variables."
+"variables. A subpattern can also be bound to a variable, using `variable @ "
+"pattern`. For example:"
msgstr ""
"パターン内に登場する変数は、任意の値にマッチ **するだけでなく**、arm のアク"
"ション内ではマッチした値が変数の名前に束縛されます。従って、 `(0f, y)` は1つ"
"数に束縛されます。"
#. type: Plain text
-#: doc/tutorial.md:530
+#: src/doc/tutorial.md:540
msgid ""
"Any `match` arm can have a guard clause (written `if EXPR`), called a "
"*pattern guard*, which is an expression of type `bool` that determines, "
"用例が示されています。"
#. type: Plain text
-#: doc/tutorial.md:535
+#: src/doc/tutorial.md:545
msgid ""
"You've already seen simple `let` bindings, but `let` is a little fancier "
"than you've been led to believe. It, too, supports destructuring patterns. "
"定義することが可能です。"
#. type: Plain text
-#: doc/tutorial.md:540
+#: src/doc/tutorial.md:550
msgid ""
"~~~~ # fn get_tuple_of_two_ints() -> (int, int) { (1, 1) } let (a, b) = "
"get_tuple_of_two_ints(); ~~~~"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:544
+#: src/doc/tutorial.md:554
msgid ""
"Let bindings only work with _irrefutable_ patterns: that is, patterns that "
"can never fail to match. This excludes `let` from matching literals and most "
"ん。"
#. type: Plain text
-#: doc/tutorial.md:546
+#: src/doc/tutorial.md:556
msgid "## Loops"
msgstr "## ループ"
#. type: Plain text
-#: doc/tutorial.md:551
+#: src/doc/tutorial.md:561
#, fuzzy
#| msgid ""
#| "`while` denotes a loop that iterates as long as its given condition "
"ション) を中断し、次の繰り返しを実行します。"
#. type: Plain text
-#: doc/tutorial.md:560
+#: src/doc/tutorial.md:570
msgid ""
"`loop` denotes an infinite loop, and is the preferred way of writing `while "
"true`:"
"が推奨されています。"
#. type: Plain text
-#: doc/tutorial.md:572
+#: src/doc/tutorial.md:582
msgid ""
"This code prints out a weird sequence of numbers and stops as soon as it "
"finds one that can be divided by five."
msgstr "このコードは 5 で割り切れる数値が現れるまで、数値を出力し続けます。"
#. type: Plain text
-#: doc/tutorial.md:574
+#: src/doc/tutorial.md:584
msgid "# Data structures"
msgstr "# データ構造"
#. type: Plain text
-#: doc/tutorial.md:576
+#: src/doc/tutorial.md:586
msgid "## Structs"
msgstr "## 構造体"
#. type: Plain text
-#: doc/tutorial.md:581
+#: src/doc/tutorial.md:591
msgid ""
"Rust struct types must be declared before they are used using the `struct` "
"syntax: `struct Name { field1: T1, field2: T2 [, ...] }`, where `T1`, "
"うに、構造体宣言から `struct` を取り除いたものと同じ構文で作成します。"
#. type: Plain text
-#: doc/tutorial.md:585
+#: src/doc/tutorial.md:595
msgid ""
"Structs are quite similar to C structs and are even laid out the same way in "
"memory (so you can read from a Rust struct in C, and vice-versa). Use the "
"フィールドにアクセスするには、 `mypoint.x` のように、ドット演算子を用います。"
#. type: Plain text
-#: doc/tutorial.md:595
+#: src/doc/tutorial.md:602
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~~\n"
+"struct Point {\n"
+" x: f64,\n"
+" y: f64\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:605
#, fuzzy
#| msgid ""
#| "Inherited mutability means that any field of a struct may be mutable, if "
"フィールドに配置された構造体のフィールドもまた、ミュータブルになります) 。"
#. type: Plain text
-#: doc/tutorial.md:599
+#: src/doc/tutorial.md:609
msgid ""
"With a value (say, `mypoint`) of such a type in a mutable location, you can "
"do `mypoint.y += 1.0`. But in an immutable location, such an assignment to a "
"このような代入操作は型エラーとなります。"
#. type: Plain text
-#: doc/tutorial.md:604
+#: src/doc/tutorial.md:614
msgid ""
"~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point "
"{ x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/tutorial.md:608
+#: src/doc/tutorial.md:618
+#, fuzzy
+#| msgid ""
+#| "mypoint.y += 1.0; // mypoint is mutable, and its fields as well origin.y "
+#| "+= 1.0; // ERROR: assigning to immutable field ~~~~"
msgid ""
-"mypoint.y += 1.0; // mypoint is mutable, and its fields as well origin.y += "
-"1.0; // ERROR: assigning to immutable field ~~~~"
+"mypoint.y += 1.0; // `mypoint` is mutable, and its fields as well origin.y "
+"+= 1.0; // ERROR: assigning to immutable field ~~~~"
msgstr ""
"mypoint.y += 1.0;\n"
"// mypoint はミュータブル\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:611
+#: src/doc/tutorial.md:621
msgid ""
"`match` patterns destructure structs. The basic syntax is `Name { fieldname: "
"pattern, ... }`:"
"は、 `Name { fieldname: pattern, ... }` という構文を持ちます。"
#. type: Plain text
-#: doc/tutorial.md:620
+#: src/doc/tutorial.md:630
#, fuzzy, no-wrap
#| msgid "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: 20f }; println(fmt!(\"%f\", point.x)); ~~~"
msgid ""
"~~~"
#. type: Plain text
-#: doc/tutorial.md:627
+#: src/doc/tutorial.md:637
#, fuzzy
#| msgid ""
#| "In general, the field names of a struct do not have to appear in the same "
"フィールドを無視することができます。"
#. type: Plain text
-#: doc/tutorial.md:635
+#: src/doc/tutorial.md:645
#, fuzzy, no-wrap
#| msgid "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: 20f }; println(fmt!(\"%f\", point.x)); ~~~"
msgid ""
"~~~"
#. type: Plain text
-#: doc/tutorial.md:637
+#: src/doc/tutorial.md:647
msgid "## Enums"
msgstr "## 列挙型"
#. type: Plain text
-#: doc/tutorial.md:640
+#: src/doc/tutorial.md:650
+#, fuzzy
+#| msgid ""
+#| "Enums are datatypes that have several alternate representations. For "
+#| "example, consider the type shown earlier:"
msgid ""
"Enums are datatypes that have several alternate representations. For "
-"example, consider the type shown earlier:"
+"example, consider the following type:"
msgstr ""
"列挙型 (enum) は、いくつかの代替表現を持つデータ型です。例えば、以下の型につ"
"いて考えます。"
#. type: Plain text
-#: doc/tutorial.md:654
+#: src/doc/tutorial.md:664
#, fuzzy
#| msgid ""
#| "A value of this type is either a `Circle`, in which case it contains a "
"静的に保証されるという点でより良いものとなっています。"
#. type: Plain text
-#: doc/tutorial.md:660
+#: src/doc/tutorial.md:670
#, fuzzy
#| msgid ""
#| "The above declaration will define a type `Shape` that can refer to such "
"ことができます。"
#. type: Plain text
-#: doc/tutorial.md:663
+#: src/doc/tutorial.md:673
msgid ""
"Enum variants need not have parameters. This `enum` declaration, for "
"example, is equivalent to a C enum:"
"言は C の列挙型と等価です。"
#. type: Plain text
-#: doc/tutorial.md:675
+#: src/doc/tutorial.md:685
msgid ""
"This declaration defines `North`, `East`, `South`, and `West` as constants, "
"all of which have type `Direction`."
"す。"
#. type: Plain text
-#: doc/tutorial.md:679
+#: src/doc/tutorial.md:689
msgid ""
"When an enum is C-like (that is, when none of the variants have parameters), "
"it is possible to explicitly set the discriminator values to a constant "
"識別値 (discriminator value) を明示的に指定することも可能です。"
#. type: Plain text
-#: doc/tutorial.md:692
+#: src/doc/tutorial.md:702
msgid ""
"If an explicit discriminator is not specified for a variant, the value "
"defaults to the value of the previous variant plus one. If the first variant "
"で言うと、 `North` は 0、 `East` は 1、 `South` は 2、`West` は3となります。"
#. type: Plain text
-#: doc/tutorial.md:695
+#: src/doc/tutorial.md:705
msgid ""
"When an enum is C-like, you can apply the `as` cast operator to convert it "
"to its discriminator value as an `int`."
"値へ変換することができます。"
#. type: Plain text
-#: doc/tutorial.md:699
+#: src/doc/tutorial.md:709
msgid ""
"For enum types with multiple variants, destructuring is the only way to get "
"at their contents. All variant constructors can be used as patterns, as in "
"トのコンストラクタは、パターンとして用いることもできます。"
#. type: Plain text
-#: doc/tutorial.md:716
+#: src/doc/tutorial.md:726
#, fuzzy
#| msgid ""
#| "You can write a lone `_` to ignore an individual field, and can ignore "
"い形式で記述します。"
#. type: Plain text
-#: doc/tutorial.md:731
+#: src/doc/tutorial.md:741
msgid "Enum variants may also be structs. For example:"
msgstr "以下の例のように、列挙型バリアントを構造体にすることも可能です。"
#. type: Plain text
-#: doc/tutorial.md:755
+#: src/doc/tutorial.md:765
msgid "## Tuples"
msgstr "## タプル"
#. type: Plain text
-#: doc/tutorial.md:760
+#: src/doc/tutorial.md:770
#, fuzzy
#| msgid ""
#| "Tuples in Rust behave exactly like structs, except that their fields do "
"す (必要ならば、ユニット型 `()` を 0 要素のタプルと見なすことはできます。)"
#. type: Plain text
-#: doc/tutorial.md:767
+#: src/doc/tutorial.md:777
#, fuzzy, no-wrap
#| msgid ""
#| "For example:\n"
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:769
+#: src/doc/tutorial.md:779
msgid "## Tuple structs"
msgstr "## タプル構造体"
#. type: Plain text
-#: doc/tutorial.md:774
+#: src/doc/tutorial.md:784
msgid ""
"Rust also has _tuple structs_, which behave like both structs and tuples, "
"except that, unlike tuples, tuple structs have names (so `Foo(1, 2)` has a "
"フィールド__ は名前を持ちません。"
#. type: Plain text
-#: doc/tutorial.md:784
+#: src/doc/tutorial.md:794
#, fuzzy, no-wrap
#| msgid ""
#| "For example:\n"
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:791
+#: src/doc/tutorial.md:801
msgid ""
"There is a special case for tuple structs with a single field, which are "
"sometimes called \"newtypes\" (after Haskell's \"newtype\" feature). These "
"きます。この新しい型は、元にした型とは異なった型として扱われます。"
#. type: Plain text
-#: doc/tutorial.md:795
+#: src/doc/tutorial.md:805
msgid "~~~~ struct GizmoId(int); ~~~~"
msgstr ""
"~~~~\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:798
+#: src/doc/tutorial.md:808
#, fuzzy
#| msgid ""
#| "Types like this can be useful to differentiate between data that have the "
"データを扱う場合に用いると便利です。"
#. type: Plain text
-#: doc/tutorial.md:803
+#: src/doc/tutorial.md:813
msgid "~~~~ struct Inches(int); struct Centimeters(int); ~~~~"
msgstr ""
"~~~~\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:807
+#: src/doc/tutorial.md:817
#, fuzzy
#| msgid ""
#| "The above definitions allow for a simple way for programs to avoid "
"が可能になります。"
#. type: Plain text
-#: doc/tutorial.md:810
+#: src/doc/tutorial.md:820
#, fuzzy
#| msgid "~~~~ struct GizmoId(int); ~~~~"
msgid "~~~ # struct Inches(int);"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:817
+#: src/doc/tutorial.md:827
msgid "# Functions"
msgstr "# 関数"
#. type: Plain text
-#: doc/tutorial.md:825
+#: src/doc/tutorial.md:835
#, fuzzy
#| msgid ""
#| "We've already seen several function definitions. Like all other static "
"ができます (モジュールについては、[後述](#モジュールとクレート)します) 。"
#. type: Plain text
-#: doc/tutorial.md:831
+#: src/doc/tutorial.md:841
#, fuzzy, no-wrap
#| msgid "~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
msgid ""
"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
#. type: Plain text
-#: doc/tutorial.md:836
+#: src/doc/tutorial.md:846
msgid ""
"The `return` keyword immediately returns from the body of a function. It is "
"optionally followed by an expression to return. A function can also return a "
"値) も関数の戻り値になります。"
#. type: Plain text
-#: doc/tutorial.md:842
+#: src/doc/tutorial.md:852
#, fuzzy, no-wrap
#| msgid "~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
msgid ""
"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
#. type: Plain text
-#: doc/tutorial.md:849
+#: src/doc/tutorial.md:859
msgid ""
"It's better Rust style to write a return value this way instead of writing "
"an explicit `return`. The utility of `return` comes in when returning early "
"の型や、戻り値を返す処理を省略することが可能です。以下の2つの関数は等価です。"
#. type: Plain text
-#: doc/tutorial.md:852
+#: src/doc/tutorial.md:862
msgid "~~~~ fn do_nothing_the_hard_way() -> () { return (); }"
msgstr ""
"~~~~\n"
"fn do_nothing_the_hard_way() -> () { return (); }"
#. type: Plain text
-#: doc/tutorial.md:855
+#: src/doc/tutorial.md:865
msgid "fn do_nothing_the_easy_way() { } ~~~~"
msgstr ""
"fn do_nothing_the_easy_way() { }\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:857
+#: src/doc/tutorial.md:867
msgid ""
"Ending the function with a semicolon like so is equivalent to returning `()`."
msgstr "以下のように、セミコロンで終わる関数は `()` を返す関数と等価です。"
#. type: Plain text
-#: doc/tutorial.md:861
+#: src/doc/tutorial.md:871
msgid ""
"~~~~ fn line(a: int, b: int, x: int) -> int { a * x + b } fn oops(a: int, b: "
"int, x: int) -> () { a * x + b; }"
"fn oops(a: int, b: int, x: int) -> () { a * x + b; }"
#. type: Plain text
-#: doc/tutorial.md:865
+#: src/doc/tutorial.md:875
msgid "assert!(8 == line(5, 3, 1)); assert!(() == oops(5, 3, 1)); ~~~~"
msgstr ""
"assert!(8 == line(5, 3, 1));\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:869
+#: src/doc/tutorial.md:879
msgid ""
"As with `match` expressions and `let` bindings, function arguments support "
"pattern destructuring. Like `let`, argument patterns must be irrefutable, as "
"し、呼び出し元へ返します。"
#. type: Plain text
-#: doc/tutorial.md:873
+#: src/doc/tutorial.md:883
msgid "~~~ fn first((value, _): (int, f64)) -> int { value } ~~~"
msgstr ""
"~~~\n"
"~~~"
#. type: Plain text
-#: doc/tutorial.md:879
+#: src/doc/tutorial.md:889
msgid ""
"A *destructor* is a function responsible for cleaning up the resources used "
"by an object when it is no longer accessible. Destructors can be defined to "
"リのようなリソースの解放を処理するために定義することができます。"
#. type: Plain text
-#: doc/tutorial.md:883
+#: src/doc/tutorial.md:893
#, fuzzy
#| msgid ""
#| "Objects are never accessible after their destructor has been called, so "
"び出されます。"
#. type: Plain text
-#: doc/tutorial.md:885
+#: src/doc/tutorial.md:895
msgid ""
"The `~` sigil represents a unique handle for a memory allocation on the heap:"
msgstr ""
"す。"
#. type: Plain text
-#: doc/tutorial.md:897
+#: src/doc/tutorial.md:907
msgid ""
"Rust includes syntax for heap memory allocation in the language since it's "
"commonly used, but the same semantics can be implemented by a type with a "
"り実装することが可能です。"
#. type: Plain text
-#: doc/tutorial.md:899
+#: src/doc/tutorial.md:909
msgid "# Ownership"
msgstr "# 所有権"
#. type: Plain text
-#: doc/tutorial.md:904
+#: src/doc/tutorial.md:914
msgid ""
"Rust formalizes the concept of object ownership to delegate management of an "
"object's lifetime to either a variable or a task-local garbage collector. An "
"断します。"
#. type: Plain text
-#: doc/tutorial.md:908
+#: src/doc/tutorial.md:918
#, fuzzy
#| msgid ""
#| "Ownership is recursive, so mutability is inherited recursively and a "
"きにデストラクタが呼び出されます。"
#. type: Plain text
-#: doc/tutorial.md:912
+#: src/doc/tutorial.md:922
msgid ""
"~~~~ // the struct owns the objects contained in the `x` and `y` fields "
"struct Foo { x: int, y: ~int }"
"struct Foo { x: int, y: ~int }"
#. type: Plain text
-#: doc/tutorial.md:919
+#: src/doc/tutorial.md:929
#, no-wrap
msgid ""
"{\n"
"// `a` の含まれているスコープから抜けるとき、 構造体のフィールドの `~int` のデストラクタが呼ばれる\n"
#. type: Plain text
-#: doc/tutorial.md:924
+#: src/doc/tutorial.md:934
msgid ""
"// `b` is mutable, and the mutability is inherited by the objects it owns "
"let mut b = Foo { x: 5, y: ~10 }; b.x = 10; ~~~~"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:931
+#: src/doc/tutorial.md:941
#, fuzzy
#| msgid ""
#| "If an object doesn't contain garbage-collected boxes, it consists of a "
"** ことは依然可能です。"
#. type: Plain text
-#: doc/tutorial.md:934
+#: src/doc/tutorial.md:944
#, fuzzy
#| msgid ""
#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
#. type: Plain text
-#: doc/tutorial.md:963
+#: src/doc/tutorial.md:946
+#, fuzzy
+#| msgid "# Introduction"
+msgid "# Implementing a linked list"
+msgstr "# イントロダクション"
+
+#. type: Plain text
+#: src/doc/tutorial.md:973
#, fuzzy
#| msgid "# Boxes"
msgid "## Boxes"
msgstr "# ボックス"
#. type: Plain text
-#: doc/tutorial.md:1032
+#: src/doc/tutorial.md:986
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"struct Foo {\n"
+" a: u32,\n"
+" b: u32,\n"
+" c: u32,\n"
+" d: u32\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:1047
#, fuzzy
#| msgid "# Move semantics"
msgid "## Move semantics"
msgstr "# ムーブセマンティクス"
#. type: Plain text
-#: doc/tutorial.md:1076
+#: src/doc/tutorial.md:1091
+#, fuzzy
+#| msgid ""
+#| "~~~~ let x = ~5; let y = x.clone(); // y is a newly allocated box let z = "
+#| "x; // no new memory allocated, x can no longer be used ~~~~"
msgid ""
-"~~~~ let x = ~5; let y = x.clone(); // y is a newly allocated box let z = "
-"x; // no new memory allocated, x can no longer be used ~~~~"
+"~~~~ let x = ~5; let y = x.clone(); // `y` is a newly allocated box let z = "
+"x; // no new memory allocated, `x` can no longer be used ~~~~"
msgstr ""
"~~~~\n"
"let x = ~5;\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:1105
+#: src/doc/tutorial.md:1120
msgid ""
"~~~~ let r = ~13; let mut s = r; // box becomes mutable *s += 1; let t = "
"s; // box becomes immutable ~~~~"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:1129
+#: src/doc/tutorial.md:1144
#, fuzzy
msgid "## References"
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/tutorial.md:1175
+#: src/doc/tutorial.md:1190
#, fuzzy
#| msgid "## Using other crates"
msgid "## Lists of other types"
msgstr "## 他のクレートの利用"
#. type: Plain text
-#: doc/tutorial.md:1307
+#: src/doc/tutorial.md:1322
#, fuzzy
#| msgid "## Managed boxes"
msgid "# More on boxes"
msgstr "## マネージドボックス"
#. type: Plain text
-#: doc/tutorial.md:1338
+#: src/doc/tutorial.md:1353
msgid "~~~~ let x = 5; // immutable let mut y = 5; // mutable y += 2;"
msgstr ""
"~~~~\n"
"y += 2;"
#. type: Plain text
-#: doc/tutorial.md:1343
+#: src/doc/tutorial.md:1358
+#, fuzzy
+#| msgid ""
+#| "let x = ~5; // immutable let mut y = ~5; // mutable *y += 2; // the * "
+#| "operator is needed to access the contained value ~~~~"
msgid ""
-"let x = ~5; // immutable let mut y = ~5; // mutable *y += 2; // the * "
+"let x = ~5; // immutable let mut y = ~5; // mutable *y += 2; // the `*` "
"operator is needed to access the contained value ~~~~"
msgstr ""
"let x = ~5; // イミュータブル\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:1352
+#: src/doc/tutorial.md:1367
#, fuzzy
#| msgid ""
#| "Rust's borrowed pointers are a general purpose reference type. In "
"生きしないことがコンパイラにより保証されます。"
#. type: Plain text
-#: doc/tutorial.md:1354
+#: src/doc/tutorial.md:1369
msgid "As an example, consider a simple struct type, `Point`:"
msgstr "例として、シンプルな構造体型の `Point` について考えます。"
#. type: Plain text
-#: doc/tutorial.md:1365
+#: src/doc/tutorial.md:1376
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~\n"
+"struct Point {\n"
+" x: f64,\n"
+" y: f64\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:1380
msgid ""
"We can use this simple definition to allocate points in many different ways. "
"For example, in this code, each of these three local variables contains a "
"なった場所に `Point` 型のオブジェクトを割り当てています。"
#. type: Plain text
-#: doc/tutorial.md:1372
+#: src/doc/tutorial.md:1387
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/tutorial.md:1382
+#: src/doc/tutorial.md:1397
#, fuzzy
#| msgid ""
#| "Suppose we want to write a procedure that computes the distance between "
"です。"
#. type: Plain text
-#: doc/tutorial.md:1404
+#: src/doc/tutorial.md:1419
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
msgid ""
"let origin = Point { x: 0.0, y: 0.0 };"
#. type: Plain text
-#: doc/tutorial.md:1411
+#: src/doc/tutorial.md:1426
#, fuzzy
#| msgid ""
#| "Here the `&` operator is used to take the address of the variable "
"(_borrowing_) と呼びます。"
#. type: Plain text
-#: doc/tutorial.md:1417
+#: src/doc/tutorial.md:1432
#, fuzzy
#| msgid ""
#| "In the case of the boxes `managed_box` and `owned_box`, however, no "
"す。"
#. type: Plain text
-#: doc/tutorial.md:1426
+#: src/doc/tutorial.md:1441
#, fuzzy
#| msgid ""
#| "Whenever a value is borrowed, there are some limitations on what you can "
"コープを抜ける) を待たなければなりません。"
#. type: Plain text
-#: doc/tutorial.md:1429
+#: src/doc/tutorial.md:1444
#, fuzzy
#| msgid ""
#| "For a more in-depth explanation of borrowed pointers, read the [borrowed "
"してください。"
#. type: Plain text
-#: doc/tutorial.md:1431
+#: src/doc/tutorial.md:1446
msgid "## Freezing"
msgstr "## 凍結"
#. type: Plain text
-#: doc/tutorial.md:1435
+#: src/doc/tutorial.md:1450
#, fuzzy
#| msgid ""
#| "Borrowing an immutable pointer to an object freezes it and prevents "
"されます (凍結された値を変更しようとすると、コンパイルエラーとなります)。"
#. type: Plain text
-#: doc/tutorial.md:1444
-#, no-wrap
+#: src/doc/tutorial.md:1459
+#, fuzzy, no-wrap
+#| msgid ""
+#| "~~~~\n"
+#| "let mut x = 5;\n"
+#| "{\n"
+#| " let y = &x; // x is now frozen, it cannot be modified\n"
+#| "}\n"
+#| "// x is now unfrozen again\n"
+#| "# x = 3;\n"
+#| "~~~~\n"
msgid ""
"~~~~\n"
"let mut x = 5;\n"
"{\n"
-" let y = &x; // x is now frozen, it cannot be modified\n"
+" let y = &x; // `x` is now frozen, it cannot be modified\n"
"}\n"
-"// x is now unfrozen again\n"
+"// `x` is now unfrozen again\n"
"# x = 3;\n"
"~~~~\n"
msgstr ""
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:1446
+#: src/doc/tutorial.md:1461
#, fuzzy
#| msgid ""
#| "[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz [win-exe]: "
"[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe"
#. type: Plain text
-#: doc/tutorial.md:1448
+#: src/doc/tutorial.md:1463
msgid "# Dereferencing pointers"
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/tutorial.md:1451
+#: src/doc/tutorial.md:1466
msgid ""
"Rust uses the unary star operator (`*`) to access the contents of a box or "
"pointer, similarly to C."
"項スター演算子 (`*`) を使います。"
#. type: Plain text
-#: doc/tutorial.md:1456
+#: src/doc/tutorial.md:1471
msgid "~~~ let managed = @10; let owned = ~20; let borrowed = &30;"
msgstr ""
"~~~\n"
"let borrowed = &30;"
#. type: Plain text
-#: doc/tutorial.md:1459
+#: src/doc/tutorial.md:1474
msgid "let sum = *managed + *owned + *borrowed; ~~~"
msgstr ""
"let sum = *managed + *owned + *borrowed;\n"
"~~~"
#. type: Plain text
-#: doc/tutorial.md:1463
+#: src/doc/tutorial.md:1478
msgid ""
"Dereferenced mutable pointers may appear on the left hand side of "
"assignments. Such an assignment modifies the value that the pointer points "
"きます。このような代入文は、ポインタが指す値を変更します。"
#. type: Plain text
-#: doc/tutorial.md:1467
+#: src/doc/tutorial.md:1482
#, fuzzy
#| msgid "~~~ let managed = @mut 10; let mut owned = ~20;"
msgid "~~~ let managed = @10; let mut owned = ~20;"
"let mut owned = ~20;"
#. type: Plain text
-#: doc/tutorial.md:1470
+#: src/doc/tutorial.md:1485
msgid "let mut value = 30; let borrowed = &mut value;"
msgstr ""
"let mut value = 30;\n"
"let borrowed = &mut value;"
#. type: Plain text
-#: doc/tutorial.md:1478
+#: src/doc/tutorial.md:1493
msgid ""
"Pointers have high operator precedence, but lower precedence than the dot "
"operator used for field and method access. This precedence order can "
"弧だらけなものになることがあります。"
#. type: Plain text
-#: doc/tutorial.md:1488
+#: src/doc/tutorial.md:1503
#, fuzzy
#| msgid ""
#| "~~~ # struct Point { x: f64, y: f64 } # enum Shape { Rectangle(Point, "
"~~~"
#. type: Plain text
-#: doc/tutorial.md:1492
+#: src/doc/tutorial.md:1507
msgid ""
"To combat this ugliness the dot operator applies _automatic pointer "
"dereferencing_ to the receiver (the value on the left-hand side of the dot), "
"レシーバを明示的にデリファレンスする必要がなくなります。"
#. type: Plain text
-#: doc/tutorial.md:1502
+#: src/doc/tutorial.md:1517
#, fuzzy
#| msgid ""
#| "~~~ # struct Point { x: f64, y: f64 } # enum Shape { Rectangle(Point, "
"~~~"
#. type: Plain text
-#: doc/tutorial.md:1506
+#: src/doc/tutorial.md:1521
msgid ""
"You can write an expression that dereferences any number of pointers "
"automatically. For example, if you feel inclined, you could write something "
"うと思えば以下のような馬鹿げたものを書くこともできます。"
#. type: Plain text
-#: doc/tutorial.md:1512
+#: src/doc/tutorial.md:1527
#, fuzzy
#| msgid ""
#| "~~~ # struct Point { x: f64, y: f64 } let point = &@~Point { x: 10f, y: "
"~~~"
#. type: Plain text
-#: doc/tutorial.md:1514
+#: src/doc/tutorial.md:1529
msgid "The indexing operator (`[]`) also auto-dereferences."
msgstr "添字演算子 (`[]`) も自動でリファレンスを行います。"
#. type: Plain text
-#: doc/tutorial.md:1516
+#: src/doc/tutorial.md:1531
msgid "# Vectors and strings"
msgstr "# ベクタと文字列"
#. type: Plain text
-#: doc/tutorial.md:1520
+#: src/doc/tutorial.md:1535
#, fuzzy
#| msgid ""
#| "A vector is a contiguous section of memory containing zero or more values "
"場合もあります。"
#. type: Plain text
-#: doc/tutorial.md:1593
+#: src/doc/tutorial.md:1608
msgid "Square brackets denote indexing into a vector:"
msgstr "角括弧はベクタの添字を表します。"
#. type: Plain text
-#: doc/tutorial.md:1607
+#: src/doc/tutorial.md:1622
msgid "A vector can be destructured using pattern matching:"
msgstr "ベクタはパターンマッチにより destructuring することができます。"
#. type: Plain text
-#: doc/tutorial.md:1620
+#: src/doc/tutorial.md:1635
#, fuzzy
#| msgid ""
#| "Both vectors and strings support a number of useful [methods](#methods), "
"ソッド](#methods) を持ちます。以下にいくつか例を挙げます。"
#. type: Plain text
-#: doc/tutorial.md:1623
+#: src/doc/tutorial.md:1638
#, fuzzy
#| msgid "[`std::vec`]: std/vec.html [`std::str`]: std/str.html"
msgid "[`std::vec`]: std/vec/index.html [`std::str`]: std/str/index.html"
"[`std::str`]: std/str.html"
#. type: Plain text
-#: doc/tutorial.md:1635
+#: src/doc/tutorial.md:1650
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~ use std::rc::Rc;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/tutorial.md:1654
+#: src/doc/tutorial.md:1669
#, fuzzy
#| msgid "~~~~ use std::task::spawn;"
msgid "~~~ use std::gc::Gc;"
"use std::task::spawn;"
#. type: Plain text
-#: doc/tutorial.md:1671
+#: src/doc/tutorial.md:1686
msgid "# Closures"
msgstr "# クロージャ"
#. type: Plain text
-#: doc/tutorial.md:1676
+#: src/doc/tutorial.md:1691
msgid ""
"Named functions, like those we've seen so far, may not refer to local "
"variables declared outside the function: they do not close over their "
"コードを書くことはできません。"
#. type: Plain text
-#: doc/tutorial.md:1679
+#: src/doc/tutorial.md:1694
msgid "~~~~ {.ignore} let foo = 10;"
msgstr ""
"~~~~ {.ignore}\n"
"let foo = 10;"
#. type: Plain text
-#: doc/tutorial.md:1684
+#: src/doc/tutorial.md:1699
#, no-wrap
msgid ""
"fn bar() -> int {\n"
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:1687
+#: src/doc/tutorial.md:1702
msgid ""
"Rust also supports _closures_, functions that can access variables in the "
"enclosing scope."
"ポートしています。"
#. type: Plain text
-#: doc/tutorial.md:1690
+#: src/doc/tutorial.md:1705
msgid "~~~~ fn call_closure_with_ten(b: |int|) { b(10); }"
msgstr ""
"~~~~\n"
"fn call_closure_with_ten(b: |int|) { b(10); }"
#. type: Plain text
-#: doc/tutorial.md:1693
+#: src/doc/tutorial.md:1708
#, fuzzy
#| msgid ""
#| "let captured_var = 20; let closure = |arg| println(fmt!(\"captured_var="
"arg));"
#. type: Plain text
-#: doc/tutorial.md:1696
+#: src/doc/tutorial.md:1711
msgid "call_closure_with_ten(closure); ~~~~"
msgstr ""
"call_closure_with_ten(closure);\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:1702
+#: src/doc/tutorial.md:1717
msgid ""
"Closures begin with the argument list between vertical bars and are followed "
"by a single expression. Remember that a block, `{ <expr1>; <expr2>; ... }`, "
"場合、ブロックの値は最後の式の値となり、そうでなければ `()` となります。"
#. type: Plain text
-#: doc/tutorial.md:1707
+#: src/doc/tutorial.md:1722
msgid ""
"The types of the arguments are generally omitted, as is the return type, "
"because the compiler can almost always infer them. In the rare case where "
"場合は、引数と戻り値の型注釈を付けることがあります。"
#. type: Plain text
-#: doc/tutorial.md:1711
+#: src/doc/tutorial.md:1726
msgid "~~~~ let square = |x: int| -> uint { (x * x) as uint }; ~~~~"
msgstr ""
"~~~~\n"
"~~~~~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:1715
+#: src/doc/tutorial.md:1730
msgid ""
"There are several forms of closure, each with its own role. The most common, "
"called a _stack closure_, has type `||` and can directly access local "
"カル変数に直接アクセスすることができます。"
#. type: Plain text
-#: doc/tutorial.md:1720
+#: src/doc/tutorial.md:1735
msgid "~~~~ let mut max = 0; [1, 2, 3].map(|x| if *x > max { max = *x }); ~~~~"
msgstr ""
"~~~~\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:1729
+#: src/doc/tutorial.md:1744
msgid ""
"Stack closures are very efficient because their environment is allocated on "
"the call stack and refers by pointer to captured locals. To ensure that "
"ず、スタッククロージャは Rust のコードのあちこちに登場します。"
#. type: Plain text
-#: doc/tutorial.md:1731
+#: src/doc/tutorial.md:1746
msgid "## Owned closures"
msgstr "## 所有クロージャ"
#. type: Plain text
-#: doc/tutorial.md:1738
+#: src/doc/tutorial.md:1753
msgid ""
"Owned closures, written `proc`, hold on to things that can safely be sent "
"between processes. They copy the values they close over, much like managed "
"利用されます。"
#. type: Plain text
-#: doc/tutorial.md:1740
+#: src/doc/tutorial.md:1755
msgid "## Closure compatibility"
msgstr "## クロージャの互換性"
#. type: Plain text
-#: doc/tutorial.md:1747
+#: src/doc/tutorial.md:1762
msgid ""
"Rust closures have a convenient subtyping property: you can pass any kind of "
"closure (as long as the arguments and return types match) to functions that "
"ロージャを渡すことができるよになります。"
#. type: Plain text
-#: doc/tutorial.md:1755
+#: src/doc/tutorial.md:1770
msgid ""
"~~~~ fn call_twice(f: ||) { f(); f(); } let closure = || { \"I'm a closure, "
"and it doesn't matter what type I am\"; }; fn function() { \"I'm a normal "
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:1759
+#: src/doc/tutorial.md:1774
msgid ""
"> ***Note:*** Both the syntax and the semantics will be changing > in small "
"ways. At the moment they can be unsound in some > scenarios, particularly "
"舞いが起こされる場合があります。"
#. type: Plain text
-#: doc/tutorial.md:1761
+#: src/doc/tutorial.md:1776
msgid "## Do syntax"
msgstr "## do 構文"
#. type: Plain text
-#: doc/tutorial.md:1764
+#: src/doc/tutorial.md:1779
#, fuzzy
#| msgid ""
#| "The `do` expression provides a way to treat higher-order functions "
"を提供します。"
#. type: Plain text
-#: doc/tutorial.md:1776
+#: src/doc/tutorial.md:1791
msgid ""
"As a caller, if we use a closure to provide the final operator argument, we "
"can write it in a way that has a pleasant, block-like structure."
"コードを書くことが可能です。"
#. type: Plain text
-#: doc/tutorial.md:1786
-#, fuzzy
-#| msgid ""
-#| "This is such a useful pattern that Rust has a special form of function "
-#| "call that can be written more like a built-in control structure:"
-msgid ""
-"This is such a useful pattern that Rust has a special form of function call "
-"for these functions."
-msgstr ""
-"このような便利なパターンに対応するため、Rust には、言語組み込みの制御構造のよ"
-"うな記述が可能な、特別な関数呼び出し形式があります。"
-
-#. type: Plain text
-#: doc/tutorial.md:1798
-#, fuzzy
-#| msgid ""
-#| "The call is prefixed with the keyword `do` and, instead of writing the "
-#| "final closure inside the argument list, it appears outside of the "
-#| "parentheses, where it looks more like a typical block of code."
-msgid ""
-"The call is prefixed with the keyword `do` and, instead of writing the final "
-"procedure inside the argument list, it appears outside of the parentheses, "
-"where it looks more like a typical block of code."
-msgstr ""
-"関数呼び出しの前には `do` キーワードをつけ、引数リストの中に最後のクロージャ"
-"引数を書くのではなく、普通のコードブロックのように、丸括弧の外に記述します。"
-
-#. type: Plain text
-#: doc/tutorial.md:1803
-msgid ""
-"`do` is a convenient way to create tasks with the `task::spawn` function. "
-"`spawn` has the signature `spawn(fn: proc())`. In other words, it is a "
-"function that takes an owned closure that takes no arguments."
-msgstr ""
-"`task::spawn` 関数を用いてタスクを生成する場合、 `do` を用いると便利です。"
-"`spawn` は、 `spawn(fn: proc())` という方を持っています。言い換えると、"
-"`spawn` は「引数をとらない所有クロージャ」を引数としてとる関数ということで"
-"す。"
-
-#. type: Plain text
-#: doc/tutorial.md:1806 doc/tutorial.md:1818
-msgid "~~~~ use std::task::spawn;"
-msgstr ""
-"~~~~\n"
-"use std::task::spawn;"
-
-#. type: Plain text
-#: doc/tutorial.md:1815
-msgid ""
-"Look at all those bars and parentheses -- that's two empty argument lists "
-"back to back. Since that is so unsightly, empty argument lists may be "
-"omitted from `do` expressions."
-msgstr ""
-"このコードの丸括弧と縦棒に注目してください。立て続けに2の空の引数リストが現れ"
-"ているます。これは非常に見苦しいので、`do` 式では空の引数リストを省略すること"
-"が可能です。"
-
-#. type: Plain text
-#: doc/tutorial.md:1826
+#: src/doc/tutorial.md:1813
msgid ""
"If you want to see the output of `debug!` statements, you will need to turn "
"on `debug!` logging. To enable `debug!` logging, set the RUST_LOG "
"は `foo` になります。"
#. type: Plain text
-#: doc/tutorial.md:1828
+#: src/doc/tutorial.md:1815
msgid "# Methods"
msgstr "# メソッド"
#. type: Plain text
-#: doc/tutorial.md:1834
+#: src/doc/tutorial.md:1821
msgid ""
"Methods are like functions except that they always begin with a special "
"argument, called `self`, which has the type of the method's receiver. The "
"のです。メソッドはドット記法を浸かって `my_vec.len()` のように呼び出します。"
#. type: Plain text
-#: doc/tutorial.md:1838
+#: src/doc/tutorial.md:1825
msgid ""
"_Implementations_, written with the `impl` keyword, can define methods on "
"most Rust types, including structs and enums. As an example, let's define a "
"す。例のように、 `draw` メソッドを `Shape` 列挙型に定義してみましょう。"
#. type: Plain text
-#: doc/tutorial.md:1864
+#: src/doc/tutorial.md:1833
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} # struct Point { x: f64, y: f64 } let mut mypoint = Point { x: 1.0, y: 1.0 }; let origin = Point { x: 0.0, y: 0.0 };"
+msgid ""
+"~~~\n"
+"# fn draw_circle(p: Point, f: f64) { }\n"
+"# fn draw_rectangle(p: Point, p: Point) { }\n"
+"struct Point {\n"
+" x: f64,\n"
+" y: f64\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"# struct Point { x: f64, y: f64 }\n"
+"let mut mypoint = Point { x: 1.0, y: 1.0 };\n"
+"let origin = Point { x: 0.0, y: 0.0 };"
+
+#. type: Plain text
+#: src/doc/tutorial.md:1851
#, fuzzy
#| msgid "let s = Circle(Point { x: 1f, y: 2f }, 3f); s.draw(); ~~~"
msgid "let s = Circle(Point { x: 1.0, y: 2.0 }, 3.0); s.draw(); ~~~"
"~~~"
#. type: Plain text
-#: doc/tutorial.md:1868
+#: src/doc/tutorial.md:1855
msgid ""
"This defines an _implementation_ for `Shape` containing a single method, "
"`draw`. In most respects the `draw` method is defined like any other "
"うに定義されます。"
#. type: Plain text
-#: doc/tutorial.md:1873
+#: src/doc/tutorial.md:1860
msgid ""
"The type of `self` is the type on which the method is implemented, or a "
"pointer thereof. As an argument it is written either `self`, `&self`, "
"様、メソッドを呼び出すための互換性のあるポインタ型をもつ必要があります。"
#. type: Plain text
-#: doc/tutorial.md:1888
+#: src/doc/tutorial.md:1875
#, fuzzy, no-wrap
#| msgid ""
#| "~~~\n"
"// 自動的に借用ポインタに変換される\n"
#. type: Plain text
-#: doc/tutorial.md:1890
+#: src/doc/tutorial.md:1877
#, fuzzy
#| msgid "let s = Circle(Point { x: 1f, y: 2f }, 3f); s.draw(); ~~~"
msgid "let s = Circle(Point { x: 1.0, y: 2.0 }, 3.0);"
"~~~"
#. type: Plain text
-#: doc/tutorial.md:1896
+#: src/doc/tutorial.md:1883
#, fuzzy
#| msgid ""
#| "(@s).draw_managed(); (~s).draw_owned(); (&s).draw_borrowed(); s."
"~~~"
#. type: Plain text
-#: doc/tutorial.md:1900
+#: src/doc/tutorial.md:1887
#, fuzzy
#| msgid ""
#| "Methods typically take a borrowed pointer self type, so the compiler will "
"借用ポインタに変換するためあらゆる手段を講じます。"
#. type: Plain text
-#: doc/tutorial.md:1918
+#: src/doc/tutorial.md:1905
#, fuzzy, no-wrap
#| msgid ""
#| "~~~\n"
"// 自動的に借用ポインタに変換される\n"
#. type: Plain text
-#: doc/tutorial.md:1921
+#: src/doc/tutorial.md:1908
#, fuzzy
#| msgid "(@s).draw_borrowed(); (~s).draw_borrowed();"
msgid "(@s).draw_reference(); (~s).draw_reference();"
"(~s).draw_borrowed();"
#. type: Plain text
-#: doc/tutorial.md:1925
+#: src/doc/tutorial.md:1912
#, fuzzy
#| msgid ""
#| "// Unlike typical function arguments, the self value will // "
"s.draw_borrowed();"
#. type: Plain text
-#: doc/tutorial.md:1928
+#: src/doc/tutorial.md:1915
#, fuzzy
#| msgid "// ... and dereferenced (& &s).draw_borrowed();"
msgid "// ... and dereferenced (& &s).draw_reference();"
"(& &s).draw_borrowed();"
#. type: Plain text
-#: doc/tutorial.md:1932
+#: src/doc/tutorial.md:1919
#, fuzzy
#| msgid "// ... and dereferenced and borrowed (&@~s).draw_borrowed(); ~~~"
msgid "// ... and dereferenced and borrowed (&@~s).draw_reference(); ~~~"
"~~~"
#. type: Plain text
-#: doc/tutorial.md:1936
+#: src/doc/tutorial.md:1923
msgid ""
"Implementations may also define standalone (sometimes called \"static\") "
"methods. The absence of a `self` parameter distinguishes such methods. "
"定義することが推奨されています。"
#. type: Plain text
-#: doc/tutorial.md:1945
+#: src/doc/tutorial.md:1932
msgid ""
"To call such a method, just prefix it with the type name and a double colon:"
msgstr ""
"出せます。"
#. type: Plain text
-#: doc/tutorial.md:1956
+#: src/doc/tutorial.md:1943
msgid "# Generics"
msgstr "# ジェネリクス"
#. type: Plain text
-#: doc/tutorial.md:1964
+#: src/doc/tutorial.md:1951
msgid ""
"Throughout this tutorial, we've been defining functions that act only on "
"specific data types. With type parameters we can also define functions whose "
"`map` というジェネリック関数について考えます。"
#. type: Plain text
-#: doc/tutorial.md:1979
+#: src/doc/tutorial.md:1966
msgid ""
"When defined with type parameters, as denoted by `<T, U>`, this function can "
"be applied to any type of vector, as long as the type of `function`'s "
"任意の型のベクタを引数として渡すことが可能になります。"
#. type: Plain text
-#: doc/tutorial.md:1989
+#: src/doc/tutorial.md:1976
msgid ""
"Inside a generic function, the names of the type parameters (capitalized by "
"convention) stand for opaque types. All you can do with instances of these "
"することで、関数の引数としてとることのできる型の範囲が広がります。"
#. type: Plain text
-#: doc/tutorial.md:1991
+#: src/doc/tutorial.md:1978
msgid ""
"Generic `type`, `struct`, and `enum` declarations follow the same pattern:"
msgstr ""
"ジェネリックな型、構造体、および列挙型の宣言は、同じパターンに従います。"
#. type: Plain text
-#: doc/tutorial.md:1995
+#: src/doc/tutorial.md:1982
msgid "~~~~ use std::hashmap::HashMap; type Set<T> = HashMap<T, ()>;"
msgstr ""
"~~~~\n"
"type Set<T> = HashMap<T, ()>;"
#. type: Plain text
-#: doc/tutorial.md:2008
+#: src/doc/tutorial.md:1995
msgid ""
"These declarations can be instantiated to valid types like `Set<int>`, "
"`Stack<int>`, and `Option<int>`."
"な型を生成することができます。"
#. type: Plain text
-#: doc/tutorial.md:2014
+#: src/doc/tutorial.md:2001
msgid ""
"The last type in that example, `Option`, appears frequently in Rust code. "
"Because Rust does not have null pointers (except in unsafe code), we need "
"ることが一般的です。"
#. type: Plain text
-#: doc/tutorial.md:2033
+#: src/doc/tutorial.md:2020
msgid ""
"The Rust compiler compiles generic functions very efficiently by "
"*monomorphizing* them. *Monomorphization* is a fancy name for a simple idea: "
"の特性を持ちます。"
#. type: Plain text
-#: doc/tutorial.md:2035
+#: src/doc/tutorial.md:2022
msgid "## Traits"
msgstr "## トレイト"
#. type: Plain text
-#: doc/tutorial.md:2047
+#: src/doc/tutorial.md:2034
#, fuzzy
#| msgid ""
#| "Within a generic function the operations available on generic types are "
"より、型パラメータが示す得る型の集合を限定することができます。"
#. type: Plain text
-#: doc/tutorial.md:2054
+#: src/doc/tutorial.md:2041
#, fuzzy
#| msgid ""
#| "As motivation, let us consider copying in Rust. The `clone` method is "
"クタをもつ型をコピーすることはできません。"
#. type: Plain text
-#: doc/tutorial.md:2060
+#: src/doc/tutorial.md:2047
#, fuzzy
#| msgid ""
#| "This complicates handling of generic functions. If you have a type "
"う。"
#. type: Plain text
-#: doc/tutorial.md:2067
+#: src/doc/tutorial.md:2054
#, no-wrap
msgid ""
"~~~~ {.ignore}\n"
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:2073
+#: src/doc/tutorial.md:2060
#, fuzzy
#| msgid ""
#| "However, we can tell the compiler that the `head` function is only for "
"ドを使うことで、値のコピーを明示的に作成し、戻り値として返すことができます。"
#. type: Plain text
-#: doc/tutorial.md:2080
+#: src/doc/tutorial.md:2067
#, no-wrap
msgid ""
"~~~~\n"
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:2090
+#: src/doc/tutorial.md:2077
#, fuzzy
#| msgid ""
#| "This says that we can call `head` on any type `T` as long as that type "
"レイトを実装していない型に対して `head` を呼び出すことはできません。"
#. type: Plain text
-#: doc/tutorial.md:2095
+#: src/doc/tutorial.md:2082
#, fuzzy
#| msgid ""
#| "While most traits can be defined and implemented by user code, two traits "
"上書きすることはできません。"
#. type: Plain text
-#: doc/tutorial.md:2099
+#: src/doc/tutorial.md:2086
#, fuzzy, no-wrap
#| msgid ""
#| "* `Send` - Sendable types.\n"
"マネージドボックスやマネージドクロージャ、借用ポインタを含まない場合、型は送信可能である。"
#. type: Plain text
-#: doc/tutorial.md:2103
+#: src/doc/tutorial.md:2090
#, fuzzy, no-wrap
#| msgid ""
#| "* `Freeze` - Constant (immutable) types.\n"
"本質的に変更可能な値を含まない型のことです。本質的に変更可能な値には、`@mut` や標準ライブラリで定義されている `Cell` が含まれます。\n"
#. type: Plain text
-#: doc/tutorial.md:2112
+#: src/doc/tutorial.md:2099
msgid ""
"> ***Note:*** These two traits were referred to as 'kinds' in earlier > "
"iterations of the language, and often still are."
"でもそう呼ばれる場合があります。"
#. type: Plain text
-#: doc/tutorial.md:2118
+#: src/doc/tutorial.md:2105
#, fuzzy
#| msgid ""
#| "Additionally, the `Drop` trait is used to define destructors. This trait "
"されるメソッドを1つ定義しています。"
#. type: Plain text
-#: doc/tutorial.md:2135
+#: src/doc/tutorial.md:2110
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~\n"
+"struct TimeBomb {\n"
+" explosivity: uint\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2122
msgid ""
"It is illegal to call `drop` directly. Only code inserted by the compiler "
"may call it."
"が `drop` を呼び出すことができます。"
#. type: Plain text
-#: doc/tutorial.md:2137
+#: src/doc/tutorial.md:2124
msgid "## Declaring and implementing traits"
msgstr "## トレイトの宣言と実装"
#. type: Plain text
-#: doc/tutorial.md:2142
+#: src/doc/tutorial.md:2129
#, fuzzy
#| msgid ""
#| "A trait consists of a set of methods without bodies, or may be empty, as "
"のを表しメソッドを1つもつ `Printable` トレイトは以下のように宣言できます。"
#. type: Plain text
-#: doc/tutorial.md:2148
+#: src/doc/tutorial.md:2135
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
msgid ""
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2161
+#: src/doc/tutorial.md:2148
#, fuzzy
#| msgid ""
#| "Traits may be implemented for specific types with [impls]. An impl that "
"定義の先頭にトレイトの名前を含みます。"
#. type: Plain text
-#: doc/tutorial.md:2163
+#: src/doc/tutorial.md:2150
msgid "[impls]: #methods"
msgstr "[impls]: #メソッド"
#. type: Plain text
-#: doc/tutorial.md:2177
+#: src/doc/tutorial.md:2160 src/doc/tutorial.md:2206
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"impl Printable for ~str {\n"
+" fn print(&self) { println!(\"{}\", *self) }\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2164
msgid "# 1.print(); # (~\"foo\").print(); ~~~~"
msgstr ""
"# 1.print();\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2180
+#: src/doc/tutorial.md:2167
#, fuzzy
#| msgid ""
#| "Methods defined in an implementation of a trait may be called just like "
"されるでしょう。"
#. type: Plain text
-#: doc/tutorial.md:2182
+#: src/doc/tutorial.md:2169
#, fuzzy
#| msgid "## Deriving implementations for traits"
msgid "## Default method implementations in trait definitions"
msgstr "## トレイトの実装の導出"
#. type: Plain text
-#: doc/tutorial.md:2202
+#: src/doc/tutorial.md:2185
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"impl Printable for bool {\n"
+" fn print(&self) { println!(\"{:?}\", *self) }\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2189
#, fuzzy
#| msgid "# 1.print(); # (~\"foo\").print(); ~~~~"
msgid "# true.print(); # 3.14159.print(); ~~~~"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2229
+#: src/doc/tutorial.md:2216
#, fuzzy
#| msgid "# 1.print(); # (~\"foo\").print(); ~~~~"
msgid ""
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2260
+#: src/doc/tutorial.md:2227
+#, fuzzy
+#| msgid "## Tuples"
+msgid "## Type-parameterized traits"
+msgstr "## タプル"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2235
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"~~~~\n"
+"trait Seq<T> {\n"
+" fn length(&self) -> uint;\n"
+"}\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2240
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"impl<T> Seq<T> for ~[T] {\n"
+" fn length(&self) -> uint { self.len() }\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2247
msgid ""
"The implementation has to explicitly declare the type parameter that it "
"binds, `T`, before using it to specify its trait type. Rust requires this "
"れるもの) は、型を定義するのではなく、型を **参照** します。"
#. type: Plain text
-#: doc/tutorial.md:2265
+#: src/doc/tutorial.md:2252
msgid ""
"The type parameters bound by a trait are in scope in each of the method "
"declarations. So, re-declaring the type parameter `T` as an explicit type "
"る明示的な型パラメータとして再宣言すると、コンパイル時エラーとなります。"
#. type: Plain text
-#: doc/tutorial.md:2270
+#: src/doc/tutorial.md:2257
msgid ""
"Within a trait definition, `Self` is a special type that you can think of as "
"a type parameter. An implementation of the trait for any given type `T` "
"えられます。以下のトレイトは等価性演算をサポートする型を意味します。"
#. type: Plain text
-#: doc/tutorial.md:2277
+#: src/doc/tutorial.md:2264
#, no-wrap
msgid ""
"~~~~\n"
"}\n"
#. type: Plain text
-#: doc/tutorial.md:2283
+#: src/doc/tutorial.md:2270
#, no-wrap
msgid ""
"// In an impl, `self` refers just to the value of the receiver\n"
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:2288
+#: src/doc/tutorial.md:2275
msgid ""
"Notice that in the trait definition, `equals` takes a second parameter of "
"type `Self`. In contrast, in the `impl`, `equals` takes a second parameter "
"シーバの名前としてのみ使用されます。"
#. type: Plain text
-#: doc/tutorial.md:2293
+#: src/doc/tutorial.md:2280
msgid ""
"Just as in type implementations, traits can define standalone (static) "
"methods. These methods are called by prefixing the method name with the "
"め、型推論を行います。"
#. type: Plain text
-#: doc/tutorial.md:2299
+#: src/doc/tutorial.md:2286
#, fuzzy
#| msgid ""
#| "~~~~ use std::f64::consts::pi; trait Shape { fn new(area: f64) -> Self; } "
"struct Square { length: f64 }"
#. type: Plain text
-#: doc/tutorial.md:2311
+#: src/doc/tutorial.md:2298
msgid ""
"let area = 42.5; let c: Circle = Shape::new(area); let s: Square = Shape::"
"new(area); ~~~~"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2313
+#: src/doc/tutorial.md:2300
msgid "## Bounded type parameters and static method dispatch"
msgstr "## 境界型パラメータと静的メソッドディスパッチ"
#. type: Plain text
-#: doc/tutorial.md:2318
+#: src/doc/tutorial.md:2305
msgid ""
"Traits give us a language for defining predicates on types, or abstract "
"properties that types can have. We can use this language to define _bounds_ "
"なります。"
#. type: Plain text
-#: doc/tutorial.md:2333
+#: src/doc/tutorial.md:2320
msgid ""
"Declaring `T` as conforming to the `Printable` trait (as we earlier did with "
"`Clone`) makes it possible to call methods from that trait on values of type "
"ル時エラーとなります。"
#. type: Plain text
-#: doc/tutorial.md:2336
+#: src/doc/tutorial.md:2323
msgid ""
"Type parameters can have multiple bounds by separating them with `+`, as in "
"this version of `print_all` that copies elements."
"`print_all` は、ベクタの要素をコピーするバージョンです。"
#. type: Plain text
-#: doc/tutorial.md:2352
+#: src/doc/tutorial.md:2339
msgid ""
"Method calls to bounded type parameters are _statically dispatched_, "
"imposing no more overhead than normal function invocation, so are the "
"型パラメータが推奨されます。 "
#. type: Plain text
-#: doc/tutorial.md:2354
+#: src/doc/tutorial.md:2341
msgid "This usage of traits is similar to Haskell type classes."
msgstr "トレイトのこのような使い方は、Haskell の型クラスと似ています。"
#. type: Plain text
-#: doc/tutorial.md:2356
+#: src/doc/tutorial.md:2343
msgid "## Trait objects and dynamic method dispatch"
msgstr "## トレイトオブジェクトと動的メソッドディスパッチ"
#. type: Plain text
-#: doc/tutorial.md:2360
+#: src/doc/tutorial.md:2347
msgid ""
"The above allows us to define functions that polymorphically act on values "
"of a single unknown type that conforms to a given trait. However, consider "
"フィックにふるまう関数を定義しました。ここでは、以下の関数について考えます。"
#. type: Plain text
-#: doc/tutorial.md:2366
+#: src/doc/tutorial.md:2353
msgid ""
"~~~~ # type Circle = int; type Rectangle = int; # impl Drawable for int { fn "
"draw(&self) {} } # fn new_circle() -> int { 1 } trait Drawable { fn "
"trait Drawable { fn draw(&self); }"
#. type: Plain text
-#: doc/tutorial.md:2379
+#: src/doc/tutorial.md:2366
msgid ""
"You can call that on an array of circles, or an array of rectangles "
"(assuming those have suitable `Drawable` traits defined), but not on an "
"す。"
#. type: Plain text
-#: doc/tutorial.md:2391
+#: src/doc/tutorial.md:2378
msgid ""
"In this example, there is no type parameter. Instead, the `@Drawable` type "
"denotes any managed box value that implements the `Drawable` trait. To "
"うな値を作成するには、 `as` 演算子を使って値をオブジェクトへキャストします。"
#. type: Plain text
-#: doc/tutorial.md:2398
+#: src/doc/tutorial.md:2385
msgid ""
"~~~~ # type Circle = int; type Rectangle = bool; # trait Drawable { fn "
"draw(&self); } # fn new_circle() -> Circle { 1 } # fn new_rectangle() -> "
"# fn draw_all(shapes: &[@Drawable]) {}"
#. type: Plain text
-#: doc/tutorial.md:2401
+#: src/doc/tutorial.md:2388
msgid ""
"impl Drawable for Circle { fn draw(&self) { ... } } impl Drawable for "
"Rectangle { fn draw(&self) { ... } }"
"impl Drawable for Rectangle { fn draw(&self) { ... } }"
#. type: Plain text
-#: doc/tutorial.md:2406
+#: src/doc/tutorial.md:2393
msgid ""
"let c: @Circle = @new_circle(); let r: @Rectangle = @new_rectangle(); "
"draw_all([c as @Drawable, r as @Drawable]); ~~~~"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2414
+#: src/doc/tutorial.md:2401
msgid ""
"We omit the code for `new_circle` and `new_rectangle`; imagine that these "
"just return `Circle`s and `Rectangle`s with a default size. Note that, like "
"`@Cicle` を `~Drawable` にキャストすることはできません。"
#. type: Plain text
-#: doc/tutorial.md:2428
+#: src/doc/tutorial.md:2415
msgid ""
"~~~ # type Circle = int; type Rectangle = int; # trait Drawable { fn "
"draw(&self); } # impl Drawable for int { fn draw(&self) {} } # fn "
"~~~"
#. type: Plain text
-#: doc/tutorial.md:2433
+#: src/doc/tutorial.md:2420
msgid ""
"Method calls to trait types are _dynamically dispatched_. Since the compiler "
"doesn't know specifically which functions to call at compile time, it uses a "
"て、呼び出すメソッドの選択を実行時に行います。"
#. type: Plain text
-#: doc/tutorial.md:2435
+#: src/doc/tutorial.md:2422
msgid "This usage of traits is similar to Java interfaces."
msgstr "トレイトのこのような使い方は、Java のインターフェースと似ています。"
#. type: Plain text
-#: doc/tutorial.md:2461
+#: src/doc/tutorial.md:2448
msgid "## Trait inheritance"
msgstr "## トレイトの継承"
#. type: Plain text
-#: doc/tutorial.md:2466
+#: src/doc/tutorial.md:2453
msgid ""
"We can write a trait declaration that _inherits_ from other traits, called "
"_supertraits_. Types that implement a trait must also implement its "
"のとして定義できます。"
#. type: Plain text
-#: doc/tutorial.md:2471
+#: src/doc/tutorial.md:2458
msgid ""
"~~~~ trait Shape { fn area(&self) -> f64; } trait Circle : Shape { fn "
"radius(&self) -> f64; } ~~~~"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2473
+#: src/doc/tutorial.md:2460
msgid ""
"Now, we can implement `Circle` on a type only if we also implement `Shape`."
msgstr "`Circle` トレイトの実装は、 `Shape` を実装した型についてのみ行えます。"
#. type: Plain text
-#: doc/tutorial.md:2488
+#: src/doc/tutorial.md:2475
#, fuzzy, no-wrap
#| msgid "~~~ {.ignore} use std::f64::consts::pi; # trait Shape { fn area(&self) -> f64; } # trait Circle : Shape { fn radius(&self) -> f64; } # struct Point { x: f64, y: f64 } # struct CircleStruct { center: Point, radius: f64 } # impl Circle for CircleStruct { fn radius(&self) -> f64 { (self.area() / pi).sqrt() } } # impl Shape for CircleStruct { fn area(&self) -> f64 { pi * square(self.radius) } }"
msgid ""
"# impl Shape for CircleStruct { fn area(&self) -> f64 { pi * square(self.radius) } }"
#. type: Plain text
-#: doc/tutorial.md:2493
+#: src/doc/tutorial.md:2480
msgid ""
"Notice that methods of `Circle` can call methods on `Shape`, as our `radius` "
"implementation calls the `area` method. This is a silly way to compute the "
"ていますが、メソッド呼び出しの考え方は分かったでしょう。"
#. type: Plain text
-#: doc/tutorial.md:2497
+#: src/doc/tutorial.md:2484
msgid ""
"In type-parameterized functions, methods of the supertrait may be called on "
"values of subtrait-bound type parameters. Refering to the previous example "
"を参照してください。"
#. type: Plain text
-#: doc/tutorial.md:2506
+#: src/doc/tutorial.md:2493
#, no-wrap
msgid ""
"~~~\n"
"~~~\n"
#. type: Plain text
-#: doc/tutorial.md:2517
+#: src/doc/tutorial.md:2504
#, fuzzy
#| msgid ""
-#| "~~~ {.ignore} use std::f64::consts::pi; # trait Shape { fn "
-#| "area(&self) -> f64; } # trait Circle : Shape { fn radius(&self) -> f64; } "
-#| "# struct Point { x: f64, y: f64 } # struct CircleStruct { center: Point, "
-#| "radius: f64 } # impl Circle for CircleStruct { fn radius(&self) -> f64 "
-#| "{ (self.area() / pi).sqrt() } } # impl Shape for CircleStruct { fn "
-#| "area(&self) -> f64 { pi * square(self.radius) } }"
-msgid ""
-"~~~ {.ignore} use std::f64::consts::PI; # trait Shape { fn area(&self) -"
-"> f64; } # trait Circle : Shape { fn radius(&self) -> f64; } # struct Point "
+#| "~~~ {.ignore} use std::f64::consts::pi; # trait Shape { fn area(&self) -> "
+#| "f64; } # trait Circle : Shape { fn radius(&self) -> f64; } # struct Point "
+#| "{ x: f64, y: f64 } # struct CircleStruct { center: Point, radius: f64 } # "
+#| "impl Circle for CircleStruct { fn radius(&self) -> f64 { (self.area() / "
+#| "pi).sqrt() } } # impl Shape for CircleStruct { fn area(&self) -> f64 { pi "
+#| "* square(self.radius) } }"
+msgid ""
+"~~~ {.ignore} use std::f64::consts::PI; # trait Shape { fn area(&self) -> "
+"f64; } # trait Circle : Shape { fn radius(&self) -> f64; } # struct Point "
"{ x: f64, y: f64 } # struct CircleStruct { center: Point, radius: f64 } # "
"impl Circle for CircleStruct { fn radius(&self) -> f64 { (self.area() / PI)."
"sqrt() } } # impl Shape for CircleStruct { fn area(&self) -> f64 { PI * "
"radius) } }"
#. type: Plain text
-#: doc/tutorial.md:2522
+#: src/doc/tutorial.md:2509
msgid ""
"let concrete = @CircleStruct{center:Point{x:3f,y:4f},radius:5f}; let "
"mycircle: @Circle = concrete as @Circle; let nonsense = mycircle.radius() * "
"~~~"
#. type: Plain text
-#: doc/tutorial.md:2524
+#: src/doc/tutorial.md:2511
msgid "> ***Note:*** Trait inheritance does not actually work with objects yet"
msgstr ""
"> ***注意*** トレイトの継承は、実際にはまだオブジェクトに対しては動作しませ"
"ん。"
#. type: Plain text
-#: doc/tutorial.md:2526
+#: src/doc/tutorial.md:2513
msgid "## Deriving implementations for traits"
msgstr "## トレイトの実装の導出"
#. type: Plain text
-#: doc/tutorial.md:2533
+#: src/doc/tutorial.md:2520
msgid ""
"A small number of traits in `std` and `extra` can have implementations that "
"can be automatically derived. These instances are specified by placing the "
"に変換することが可能です。"
#. type: Plain text
-#: doc/tutorial.md:2537
+#: src/doc/tutorial.md:2524
msgid "~~~ #[deriving(Eq)] struct Circle { radius: f64 }"
msgstr ""
"~~~\n"
"struct Circle { radius: f64 }"
#. type: Plain text
-#: doc/tutorial.md:2541
+#: src/doc/tutorial.md:2528
msgid "#[deriving(Rand, ToStr)] enum ABC { A, B, C } ~~~"
msgstr ""
"#[deriving(Rand, ToStr)]\n"
"~~~"
#. type: Plain text
-#: doc/tutorial.md:2545
+#: src/doc/tutorial.md:2532
#, fuzzy
#| msgid ""
#| "The full list of derivable traits is `Eq`, `TotalEq`, `Ord`, `TotalOrd`, "
"および `ToStr` です。."
#. type: Plain text
-#: doc/tutorial.md:2547
+#: src/doc/tutorial.md:2534
#, fuzzy
#| msgid "# Modules and crates"
msgid "# Crates and the module system"
msgstr "# モジュールとクレート"
#. type: Plain text
-#: doc/tutorial.md:2552
+#: src/doc/tutorial.md:2539
msgid "## Crates"
msgstr "## クレート"
#. type: Plain text
-#: doc/tutorial.md:2567
+#: src/doc/tutorial.md:2554
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
msgid ""
"~~~~\n"
-"// main.rs\n"
+"// `main.rs`\n"
"fn main() {\n"
" println!(\"Hello world!\");\n"
"}\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2570
+#: src/doc/tutorial.md:2557
#, fuzzy
#| msgid ""
#| "The unit of independent compilation in Rust is the crate: rustc compiles "
"イルし、ライブラリか実行可能ファイルを生成します。"
#. type: Plain text
-#: doc/tutorial.md:2574
+#: src/doc/tutorial.md:2561
#, fuzzy
#| msgid "## The standard library"
msgid "## The module hierarchy"
msgstr "## 標準ライブラリ"
#. type: Plain text
-#: doc/tutorial.md:2600
+#: src/doc/tutorial.md:2587
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
msgid ""
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2608
+#: src/doc/tutorial.md:2595
#, fuzzy
#| msgid "## Managed closures"
msgid "## Paths and visibility"
msgstr "## マネージドクロージャ"
#. type: Plain text
-#: doc/tutorial.md:2620
+#: src/doc/tutorial.md:2607
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"fn main() {\n"
+" println!(\"Hello chicken!\");\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2639
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
msgid ""
"fn main() {\n"
" println!(\"Hello chicken!\");\n"
+" ::farm::chicken(); // This compiles now\n"
+"}\n"
+"~~~~\n"
msgstr ""
"~~~~ {.ignore}\n"
"// main.rs\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2659
+#: src/doc/tutorial.md:2646
#, fuzzy
#| msgid ""
#| "Visibility restrictions in Rust exist only at module boundaries. This is "
"してください。"
#. type: Plain text
-#: doc/tutorial.md:2702
+#: src/doc/tutorial.md:2689
#, fuzzy
#| msgid "# Modules and crates"
msgid "## Files and modules"
msgstr "# モジュールとクレート"
#. type: Plain text
-#: doc/tutorial.md:2732
+#: src/doc/tutorial.md:2719
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
msgid ""
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:2791
+#: src/doc/tutorial.md:2755
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} let foo = 10;"
+msgid ""
+"~~~ {.ignore}\n"
+"// `src/main.rs`\n"
+"mod plants;\n"
+"mod animals {\n"
+" mod fish;\n"
+" mod mammals {\n"
+" mod humans;\n"
+" }\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"let foo = 10;"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2761 src/doc/tutorial.md:2793
+#, fuzzy
+#| msgid "~~~~ {.ignore} let foo = 10;"
+msgid "~~~ {.notrust} src/plants.rs src/plants/mod.rs"
+msgstr ""
+"~~~~ {.ignore}\n"
+"let foo = 10;"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2778
#, fuzzy
#| msgid "~~~~ {.ignore} let foo = 10;"
-msgid "~~~ {.ignore} // src/main.rs mod plants; mod animals; ~~~"
+msgid "~~~ {.ignore} // `src/main.rs` mod plants; mod animals; ~~~"
msgstr ""
"~~~~ {.ignore}\n"
"let foo = 10;"
#. type: Plain text
-#: doc/tutorial.md:2929
+#: src/doc/tutorial.md:2786
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} let foo = 10;"
+msgid ""
+"~~~ {.ignore}\n"
+"// `src/animals.rs` or `src/animals/mod.rs`\n"
+"mod fish;\n"
+"mod mammals {\n"
+" mod humans;\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"let foo = 10;"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2820
+#, fuzzy
+#| msgid "~~~~ {.ignore} let foo = 10;"
+msgid "~~~ {.ignore} #[path=\"../../area51/alien.rs\"] mod classified; ~~~"
+msgstr ""
+"~~~~ {.ignore}\n"
+"let foo = 10;"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2897
+#, fuzzy
+#| msgid ""
+#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello "
+#| "\" + world::explore()); } ~~~~"
+msgid "fn main() { cow() } ~~~"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2916
#, fuzzy, no-wrap
#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
msgid ""
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:3004
+#: src/doc/tutorial.md:2923
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+" // Can now refer to those names directly:\n"
+" chicken();\n"
+" cow();\n"
+" barn::hay();\n"
+"}\n"
+"~~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2932
+#, fuzzy
+#| msgid ""
+#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello "
+#| "\" + world::explore()); } ~~~~"
+msgid ""
+"~~~{.ignore} // `a.rs` - crate root use b::foo; mod b; fn main() { foo(); } "
+"~~~"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2939
+#, fuzzy
+#| msgid ""
+#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello "
+#| "\" + world::explore()); } ~~~~"
+msgid ""
+"~~~{.ignore} // `b.rs` use b::c::bar; pub mod c; pub fn foo() { bar(); } ~~~"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2985
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"fn main() {\n"
+" egg_layer();\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:2991
#, fuzzy
#| msgid "# Dereferencing pointers"
msgid "## Reexporting names"
msgstr "# ポインタのデリファレンス"
#. type: Plain text
-#: doc/tutorial.md:3039
+#: src/doc/tutorial.md:3014
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"fn main() {\n"
+" farm::chicken();\n"
+" farm::cow();\n"
+" farm::hay();\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:3026
#, fuzzy
#| msgid "## Using other crates"
msgid "## Using libraries"
msgstr "## 他のクレートの利用"
#. type: Plain text
-#: doc/tutorial.md:3080
+#: src/doc/tutorial.md:3035
+#, fuzzy
+#| msgid "## Using other crates"
+msgid "For that, Rust offers you the `extern mod` declaration:"
+msgstr "## 他のクレートの利用"
+
+#. type: Plain text
+#: src/doc/tutorial.md:3045
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"fn main() {\n"
+" // The rational number '1/2':\n"
+" let one_half = ::extra::rational::Ratio::new(1, 2);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:3068
#, fuzzy
#| msgid "~~~~ {.ignore} let foo = 10;"
msgid "~~~ extern mod extra;"
"let foo = 10;"
#. type: Plain text
-#: doc/tutorial.md:3144
+#: src/doc/tutorial.md:3081
+#, fuzzy, no-wrap
+#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~"
+msgid ""
+"fn main() {\n"
+" farm::dog();\n"
+" let a_third = Ratio::new(1, 3);\n"
+"}\n"
+"~~~\n"
+msgstr ""
+"~~~~ {.ignore}\n"
+"// main.rs\n"
+"extern mod world;\n"
+"fn main() { println(~\"hello \" + world::explore()); }\n"
+"~~~~"
+
+#. type: Plain text
+#: src/doc/tutorial.md:3086
+#, fuzzy
+#| msgid "## Structs"
+msgid "## Package ids"
+msgstr "## 構造体"
+
+#. type: Plain text
+#: src/doc/tutorial.md:3123
#, fuzzy
#| msgid ""
-#| "~~~~ {.ignore} extern mod farm; extern mod my_farm (name = \"farm\", "
-#| "vers = \"2.5\"); extern mod my_auxiliary_farm (name = \"farm\", author = "
-#| "\"mjh\"); ~~~~"
+#| "~~~~ {.ignore} extern mod farm; extern mod my_farm (name = \"farm\", vers "
+#| "= \"2.5\"); extern mod my_auxiliary_farm (name = \"farm\", author = \"mjh"
+#| "\"); ~~~~"
msgid ""
-"~~~~ {.ignore} extern mod farm; extern mod farm = \"farm#2.5\"; extern "
-"mod my_farm = \"farm\"; ~~~~"
+"~~~~ {.ignore} extern mod farm; extern mod farm = \"farm#2.5\"; extern mod "
+"my_farm = \"farm\"; ~~~~"
msgstr ""
"~~~~ {.ignore}\n"
"extern mod farm;\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:3155
+#: src/doc/tutorial.md:3134
#, fuzzy
#| msgid "// Make a library (\"bin\" is the default) #[crate_type = \"lib\"];"
msgid ""
"#[crate_type = \"lib\"];"
#. type: Plain text
-#: doc/tutorial.md:3160
+#: src/doc/tutorial.md:3139
#, fuzzy
#| msgid "// Turn on a warning #[warn(non_camel_case_types)]"
msgid "// Turn on a warning #[warn(non_camel_case_types)] # fn farm() {} ~~~~"
"#[warn(non_camel_case_types)]"
#. type: Plain text
-#: doc/tutorial.md:3167
+#: src/doc/tutorial.md:3141
msgid "## A minimal example"
msgstr "## 最小限の例"
#. type: Plain text
-#: doc/tutorial.md:3169
+#: src/doc/tutorial.md:3143
#, fuzzy
#| msgid ""
#| "Now for something that you can actually compile yourself, we have these "
"す。"
#. type: Plain text
-#: doc/tutorial.md:3179
+#: src/doc/tutorial.md:3153
#, fuzzy
#| msgid ""
#| "~~~~ // world.rs #[link(name = \"world\", vers = \"1.0\")]; pub fn "
#| "explore() -> &str { \"world\" } ~~~~"
msgid ""
-"~~~~ // world.rs #[crate_id = \"world#0.42\"]; # extern mod extra; pub fn "
+"~~~~ // `world.rs` #[crate_id = \"world#0.42\"]; # extern mod extra; pub fn "
"explore() -> &'static str { \"world\" } # fn main() {} ~~~~"
msgstr ""
"~~~~\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:3185
+#: src/doc/tutorial.md:3159
#, fuzzy
#| msgid ""
-#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~"
-#| "\"hello \" + world::explore()); } ~~~~"
+#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello "
+#| "\" + world::explore()); } ~~~~"
msgid ""
-"~~~~ {.ignore} // main.rs extern mod world; fn main() { println!(\"hello "
+"~~~~ {.ignore} // `main.rs` extern mod world; fn main() { println!(\"hello "
"{}\", world::explore()); } ~~~~"
msgstr ""
"~~~~ {.ignore}\n"
"~~~~"
#. type: Plain text
-#: doc/tutorial.md:3187
+#: src/doc/tutorial.md:3161
msgid "Now compile and run like this (adjust to your platform if necessary):"
msgstr ""
"以下のようにコンパイルし、実行します (必要であれば、お使いのプラットフォーム"
"に合わせて修正してください。)"
#. type: Plain text
-#: doc/tutorial.md:3194
+#: src/doc/tutorial.md:3168
#, fuzzy, no-wrap
#| msgid ""
#| "~~~~ {.notrust}\n"
"~~~~\n"
#. type: Plain text
-#: doc/tutorial.md:3199
+#: src/doc/tutorial.md:3173
#, fuzzy
#| msgid ""
#| "Notice that the library produced contains the version in the filename as "
"キームの一員です。英数字は、クレートのメタデータを表すハッシュ値です。"
#. type: Plain text
-#: doc/tutorial.md:3201
+#: src/doc/tutorial.md:3175
#, fuzzy
#| msgid "## The standard library"
msgid "## The standard library and the prelude"
msgstr "## 標準ライブラリ"
#. type: Plain text
-#: doc/tutorial.md:3213
+#: src/doc/tutorial.md:3187
#, fuzzy
#| msgid "~~~~ {.ignore} let foo = 10;"
msgid "~~~ {.ignore} extern mod std; ~~~"
"let foo = 10;"
#. type: Plain text
-#: doc/tutorial.md:3219
+#: src/doc/tutorial.md:3193
#, fuzzy
#| msgid "~~~~ {.ignore} let foo = 10;"
msgid "~~~ {.ignore} use std::prelude::*; ~~~"
"let foo = 10;"
#. type: Plain text
-#: doc/tutorial.md:3260
+#: src/doc/tutorial.md:3234
#, fuzzy
#| msgid "## The standard library"
msgid "## The extra library"
msgstr "## 標準ライブラリ"
#. type: Plain text
-#: doc/tutorial.md:3271
+#: src/doc/tutorial.md:3246
msgid "# What next?"
msgstr "# 次のステップは?"
#. type: Plain text
-#: doc/tutorial.md:3274
+#: src/doc/tutorial.md:3249
#, fuzzy
#| msgid ""
#| "Now that you know the essentials, check out any of the additional "
"トリアルもチェックしてみてください。"
#. type: Bullet: '* '
-#: doc/tutorial.md:3286
+#: src/doc/tutorial.md:3260
+#, fuzzy
+#| msgid "[Containers and iterators](tutorial-container.html)"
+msgid "[Pointers][pointers]"
+msgstr "[コンテナとイテレータ](tutorial-container.html)"
+
+#. type: Bullet: '* '
+#: src/doc/tutorial.md:3260
+#, fuzzy
+#| msgid "% The Rust Language Tutorial"
+msgid "[Lifetimes][lifetimes]"
+msgstr "% Rust 言語チュートリアル"
+
+#. type: Bullet: '* '
+#: src/doc/tutorial.md:3260
msgid "[Tasks and communication][tasks]"
msgstr "[タスクと通信][tasks]"
#. type: Bullet: '* '
-#: doc/tutorial.md:3286
+#: src/doc/tutorial.md:3260
msgid "[Macros][macros]"
msgstr "[マクロ][macros]"
#. type: Bullet: '* '
-#: doc/tutorial.md:3286
+#: src/doc/tutorial.md:3260
msgid "[The foreign function interface][ffi]"
msgstr "[他言語間インターフェース (foreign function inferface)][ffi]"
#. type: Bullet: '* '
-#: doc/tutorial.md:3286
+#: src/doc/tutorial.md:3260
#, fuzzy
#| msgid "[Containers and iterators](tutorial-container.html)"
msgid "[Containers and iterators][container]"
msgstr "[コンテナとイテレータ](tutorial-container.html)"
#. type: Bullet: '* '
-#: doc/tutorial.md:3286
+#: src/doc/tutorial.md:3260
+#, fuzzy
+#| msgid "% The Rust Language Tutorial"
+msgid "[Testing Rust code][testing]"
+msgstr "% Rust 言語チュートリアル"
+
+#. type: Bullet: '* '
+#: src/doc/tutorial.md:3260
#, fuzzy
#| msgid "% The Rust Language Tutorial"
msgid "[The Rust Runtime][runtime]"
# generates .po for them and build .md when translated, eg:
# [po4a_langs] es fr it pt_BR
[po4a_langs] ja
-[po4a_paths] doc/po/$master.pot $lang:doc/po/$lang/$master.po
+[po4a_paths] doc/po/$master.pot $lang:src/doc/po/$lang/$master.po
# Add here below all source documents to be translated
-[type: text] doc/complement-bugreport.md $lang:doc/l10n/$lang/complement-bugreport.md
-[type: text] doc/complement-cheatsheet.md $lang:doc/l10n/$lang/complement-cheatsheet.md
-[type: text] doc/complement-lang-faq.md $lang:doc/l10n/$lang/complement-lang-faq.md
-[type: text] doc/complement-project-faq.md $lang:doc/l10n/$lang/complement-project-faq.md
-[type: text] doc/complement-usage-faq.md $lang:doc/l10n/$lang/complement-usage-faq.md
-[type: text] doc/guide-conditions.md $lang:doc/l10n/$lang/guide-conditions.md
-[type: text] doc/guide-container.md $lang:doc/l10n/$lang/guide-container.md
-[type: text] doc/guide-ffi.md $lang:doc/l10n/$lang/guide-ffi.md
-[type: text] doc/guide-lifetimes.md $lang:doc/l10n/$lang/guide-lifetimes.md
-[type: text] doc/guide-macros.md $lang:doc/l10n/$lang/guide-macros.md
-[type: text] doc/guide-pointers.md $lang:doc/l10n/$lang/guide-pointers.md
-[type: text] doc/guide-rustpkg.md $lang:doc/l10n/$lang/guide-rustpkg.md
-[type: text] doc/guide-tasks.md $lang:doc/l10n/$lang/guide-tasks.md
-[type: text] doc/guide-testing.md $lang:doc/l10n/$lang/guide-testing.md
-[type: text] doc/index.md $lang:doc/l10n/$lang/index.md
-[type: text] doc/rust.md $lang:doc/l10n/$lang/rust.md
-[type: text] doc/rustdoc.md $lang:doc/l10n/$lang/rustdoc.md
-[type: text] doc/rustpkg.md $lang:doc/l10n/$lang/rustpkg.md
-[type: text] doc/tutorial.md $lang:doc/l10n/$lang/tutorial.md
+[type: text] src/doc/complement-bugreport.md $lang:doc/l10n/$lang/complement-bugreport.md
+[type: text] src/doc/complement-cheatsheet.md $lang:doc/l10n/$lang/complement-cheatsheet.md
+[type: text] src/doc/complement-lang-faq.md $lang:doc/l10n/$lang/complement-lang-faq.md
+[type: text] src/doc/complement-project-faq.md $lang:doc/l10n/$lang/complement-project-faq.md
+[type: text] src/doc/complement-usage-faq.md $lang:doc/l10n/$lang/complement-usage-faq.md
+[type: text] src/doc/guide-conditions.md $lang:doc/l10n/$lang/guide-conditions.md
+[type: text] src/doc/guide-container.md $lang:doc/l10n/$lang/guide-container.md
+[type: text] src/doc/guide-ffi.md $lang:doc/l10n/$lang/guide-ffi.md
+[type: text] src/doc/guide-lifetimes.md $lang:doc/l10n/$lang/guide-lifetimes.md
+[type: text] src/doc/guide-macros.md $lang:doc/l10n/$lang/guide-macros.md
+[type: text] src/doc/guide-pointers.md $lang:doc/l10n/$lang/guide-pointers.md
+[type: text] src/doc/guide-runtime.md $lang:doc/l10n/$lang/guide-runtime.md
+[type: text] src/doc/guide-tasks.md $lang:doc/l10n/$lang/guide-tasks.md
+[type: text] src/doc/guide-testing.md $lang:doc/l10n/$lang/guide-testing.md
+[type: text] src/doc/index.md $lang:doc/l10n/$lang/index.md
+[type: text] src/doc/rust.md $lang:doc/l10n/$lang/rust.md
+[type: text] src/doc/rustdoc.md $lang:doc/l10n/$lang/rustdoc.md
+[type: text] src/doc/tutorial.md $lang:doc/l10n/$lang/tutorial.md