| ... | @@ -1087,7 +1087,7 @@ unwrapped == 1234</code></pre> | ... | @@ -1087,7 +1087,7 @@ unwrapped == 1234</code></pre> |
| 1087 | </td> | 1087 | </td> |
| 1088 | <td> | 1088 | <td> |
| 1089 | If <code>a</code> is <code>false</code>, returns <code>false</code> | 1089 | If <code>a</code> is <code>false</code>, returns <code>false</code> |
| 1090 | without evaluating <code>b</code>. Otherwise, retuns <code>b</code>. | 1090 | without evaluating <code>b</code>. Otherwise, returns <code>b</code>. |
| 1091 | </td> | 1091 | </td> |
| 1092 | <td> | 1092 | <td> |
| 1093 | <pre><code class="zig">false and true == false</code></pre> | 1093 | <pre><code class="zig">false and true == false</code></pre> |
| ... | @@ -1102,7 +1102,7 @@ unwrapped == 1234</code></pre> | ... | @@ -1102,7 +1102,7 @@ unwrapped == 1234</code></pre> |
| 1102 | </td> | 1102 | </td> |
| 1103 | <td> | 1103 | <td> |
| 1104 | If <code>a</code> is <code>true</code>, returns <code>true</code> | 1104 | If <code>a</code> is <code>true</code>, returns <code>true</code> |
| 1105 | without evaluating <code>b</code>. Otherwise, retuns <code>b</code>. | 1105 | without evaluating <code>b</code>. Otherwise, returns <code>b</code>. |
| 1106 | </td> | 1106 | </td> |
| 1107 | <td> | 1107 | <td> |
| 1108 | <pre><code class="zig">false or true == true</code></pre> | 1108 | <pre><code class="zig">false or true == true</code></pre> |
| ... | @@ -1483,7 +1483,7 @@ test "pointer array access" { | ... | @@ -1483,7 +1483,7 @@ test "pointer array access" { |
| 1483 | } | 1483 | } |
| 1484 | | 1484 | |
| 1485 | test "pointer slicing" { | 1485 | test "pointer slicing" { |
| 1486 | // In Zig, we prefer using slices over null-terminated pointers. | 1486 | // In Zig, we prefer slices over pointers to null-terminated arrays. |
| 1487 | // You can turn an array into a slice using slice syntax: | 1487 | // You can turn an array into a slice using slice syntax: |
| 1488 | var array = []u8{ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 }; | 1488 | var array = []u8{ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 }; |
| 1489 | const slice = array[2..4]; | 1489 | const slice = array[2..4]; |