Skip to content

Commit a3a57ba

Browse files
Update for comments
1 parent e5797d5 commit a3a57ba

2 files changed

Lines changed: 22 additions & 8 deletions

File tree

courses/rust_essentials/060_references/03_navigating.rst

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -78,11 +78,13 @@ The "Rebinder" (let mut r = &x)
7878
rf = &news_b;
7979
*rf = "Peace"; // Error
8080
81-
:error:`error[E0594]: cannot assign to '*rf', which is behind a '&'' reference`
81+
.. container:: latex_environment footnotesize
82+
83+
:error:`error[E0594]: cannot assign to '*rf', which is behind a '&'' reference`
8284

8385
.. note::
8486

85-
The reference can be redirected, but the data cannot be modified
87+
The reference *can* be redirected, but the data *cannot* be modified
8688

8789
---------------------------------
8890
The "Modifier" (let r = &mut x)
@@ -104,7 +106,7 @@ The "Modifier" (let r = &mut x)
104106

105107
.. note::
106108

107-
The reference cannot be redirected, but the data can be modified
109+
The reference *cannot* be redirected, but the data *can* be modified
108110

109111
---------------------------------------
110112
The "Free Agent" (let mut r = &mut x)
@@ -125,4 +127,4 @@ The "Free Agent" (let mut r = &mut x)
125127
126128
.. note::
127129

128-
The reference can be redirected, and the data can be modified
130+
The reference *can* be redirected, and the data *can* be modified

courses/rust_essentials/060_references/05_slices.rst

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,13 +29,25 @@ Slice Creation
2929
----------------
3030

3131
- Created by referring to a collection, and specifying the range
32-
- :rust:`&a[start..]`
32+
33+
.. container:: latex_environment scriptsize
34+
35+
.. list-table::
36+
:header-rows: 1
37+
38+
* - Syntax
39+
- Range
40+
41+
* - :rust:`&a[start..]`
3342
- Explicit start to implicit end
34-
- :rust:`&a[..end]`
43+
44+
* - :rust:`&a[..end]`
3545
- Implicit start to explicit end (*end* excluded)
36-
- :rust:`&a[..]`
46+
47+
* - :rust:`&a[..]`
3748
- Full range
38-
- :rust:`&a[start..end]`
49+
50+
* - :rust:`&a[start..end]`
3951
- Explicit start and end (*end* excluded)
4052

4153
----------------

0 commit comments

Comments
 (0)