Skip to content

Commit c5575ac

Browse files
committed
ci: generate pages at ccaf034 [ci skip]
1 parent ccaf034 commit c5575ac

File tree

1 file changed

+14
-16
lines changed

1 file changed

+14
-16
lines changed

public/1.9/book/if.html

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -186,22 +186,21 @@ <h1 class="title">if</h1>
186186

187187
<!-- systems language. So let’s talk about it, to make sure you grasp the nuances. -->
188188

189-
<p>Rustにおける <code>if</code> の扱いはさほど複雑ではありませんが、伝統的なシステムプログラミング言語のそれに比べて、
190-
動的型付け言語でみられる <code>if</code> にずっと近いものになっています。そのニュアンスをしっかり理解できるよう、
191-
さっそく説明していきましょう。</p>
189+
<p>Rustにおける <code>if</code> の扱いは さほど複雑ではありませんが、伝統的なシステムプログラミング言語のそれと比べて、
190+
動的型付け言語の <code>if</code> により近いものになっています。そのニュアンスをしっかり理解できるように、説明しましょう。</p>
192191

193-
<!-- `if` is a specific form of a more general concept, the ‘branch’. The name comes -->
192+
<!-- `if` is a specific form of a more general concept, the ‘branch’. whose name comes -->
194193

195194
<!-- from a branch in a tree: a decision point, where depending on a choice, -->
196195

197196
<!-- multiple paths can be taken. -->
198197

199-
<p><code>if</code> は一般化されたコンセプト、「分岐(branch)」の特別な形式です。この名前は木の枝(branch)を由来とし:
200-
取りうる複数のパスから、選択の決定を行うポイントを表します</p>
198+
<p><code>if</code> は より一般的なコンセプトの一つである、「分岐(branch)」の具体的な形です。この名称は、木の枝(branch)に由来します:
199+
決定点はひとつの選択に依存し、複数のパスを取ることができます</p>
201200

202201
<!-- In the case of `if`, there is one choice that leads down two paths: -->
203202

204-
<p><code>if</code> の場合は、続く2つのパスから1つを選択します</p>
203+
<p><code>if</code> の場合は、二つのパスを導く ひとつの選択があります</p>
205204

206205
<span class='rusttest'>fn main() {
207206
let x = 5;
@@ -223,13 +222,12 @@ <h1 class="title">if</h1>
223222

224223
<!-- the block is executed. If it’s `false`, then it is not. -->
225224

226-
<p>仮に <code>x</code> を別の値へと変更すると、この行は表示されません。より正確に言うなら、
227-
<code>if</code> のあとにくる式が <code>true</code> に評価された場合に、ブロックが実行されます。
228-
<code>false</code> の場合、ブロックは実行されません。</p>
225+
<p>もし、<code>x</code> を別の値に変更すると、この行は出力されません。よりわかりやすく説明すると、
226+
<code>if</code> のあとにくる式が <code>true</code> に評価された場合、そのブロックが実行されます。また、<code>false</code> の場合は、それは実行されません。</p>
229227

230228
<!-- If you want something to happen in the `false` case, use an `else`: -->
231229

232-
<p><code>false</code> の場合にも何かをしたいなら<code>else</code> を使います:</p>
230+
<p><code>false</code> の場合にも何かをしたい時は<code>else</code> を使います:</p>
233231

234232
<span class='rusttest'>fn main() {
235233
let x = 5;
@@ -252,7 +250,7 @@ <h1 class="title">if</h1>
252250

253251
<!-- If there is more than one case, use an `else if`: -->
254252

255-
<p>場合分けが複数あるときは<code>else if</code> を使います:</p>
253+
<p>複数の条件がある時は<code>else if</code> を使います:</p>
256254

257255
<span class='rusttest'>fn main() {
258256
let x = 5;
@@ -280,7 +278,7 @@ <h1 class="title">if</h1>
280278

281279
<!-- This is all pretty standard. However, you can also do this: -->
282280

283-
<p>全くもって普通ですね。しかし、次のような使い方もできるのです:</p>
281+
<p>これは当然なことですが、次のように書くこともできます:</p>
284282

285283
<span class='rusttest'>fn main() {
286284
let x = 5;
@@ -301,7 +299,7 @@ <h1 class="title">if</h1>
301299

302300
<!-- Which we can (and probably should) write like this: -->
303301

304-
<p>次のように書くこともできます(そして、大抵はこう書くべきです):</p>
302+
<p>また、次のように書くのがほとんどの場合良いでしょう:</p>
305303

306304
<span class='rusttest'>fn main() {
307305
let x = 5;
@@ -318,8 +316,8 @@ <h1 class="title">if</h1>
318316

319317
<!-- `else` always results in `()` as the value. -->
320318

321-
<p>これが出来るのは <code>if</code> が式であるためです。その式の値は、選択された分岐中の最後の式の値となります
322-
<code>else</code> のない <code>if</code> では、その値は常に <code>()</code> となります</p>
319+
<p>これが出来るのは <code>if</code> が式だからです。その式の値は、選択された条件の最後の式の値です
320+
<code>else</code> のない <code>if</code> では、その値は常に <code>()</code> になります</p>
323321

324322
<script type="text/javascript">
325323
window.playgroundUrl = "https://play.rust-lang.org";

0 commit comments

Comments
 (0)