Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create footnote so body makes sense #130

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion control-flow.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ that the braces are mandatory, but parentheses around the expression being teste
are not. Another is that `if` is an expression, so you can use it the same way
as the ternary `?:` operator in C++ (remember from the previous section that if the last
expression in a block is not terminated by a semi-colon, then it becomes the
value of the block). There is no ternary `?:` in Rust. So, the following two
value of the block).<sup>[1](#1)</sup> So, the following two
functions do the same thing:

```rust
Expand Down Expand Up @@ -231,3 +231,7 @@ are always called via the `.` operator (no `->`, more on this in another post).
We saw a few examples above (`len`, `iter`). We'll go into more detail in the
future about how they are defined and called. Most assumptions you might make
from C++ or Java are probably correct.


#### 1
There is no ternary `?:` in Rust.