Skip to content

Commit 98dd2c1

Browse files
authored
Merge pull request #3870 from rust-lang/fix-2980
Clarify function definitions vs. expressions
2 parents 743d2e2 + e2a5258 commit 98dd2c1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/ch03-03-how-functions-work.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,8 @@ assigning a value to it with the `let` keyword is a statement. In Listing 3-1,
125125
</Listing>
126126

127127
Function definitions are also statements; the entire preceding example is a
128-
statement in itself.
128+
statement in itself. (As we will see below, *calling* a function is not a
129+
statement.)
129130

130131
Statements do not return values. Therefore, you can’t assign a `let` statement
131132
to another variable, as the following code tries to do; you’ll get an error:

0 commit comments

Comments
 (0)