Skip to content

Commit 4cf4e8b

Browse files
author
Thiago Carvalho
committed
glossary
1 parent 29ff00c commit 4cf4e8b

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

src/doc/trpl/SUMMARY.md

+1
Original file line numberDiff line numberDiff line change
@@ -36,3 +36,4 @@
3636
* [Macros](macros.md)
3737
* [Compiler Plugins](plugins.md)
3838
* [Conclusion](conclusion.md)
39+
* [Glossary](glossary.md)

src/doc/trpl/glossary.md

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
% Glossary
2+
3+
In this section we briefly explain terms that you may not be familiar with.
4+
5+
This book avoids, as much as possible, overcomplicated terms. Nevertheless, the following were deemed important enough that omitting them would be a disservice to the reader.
6+
7+
### Arity
8+
9+
Arity refers to the number of arguments a function or operation takes.
10+
11+
```rust
12+
let x = (2, 3);
13+
let y = (4, 6);
14+
let z = (8, 2, 6);
15+
```
16+
17+
In the example above `x` and `y` have arity 2. `z` has arity 3.

0 commit comments

Comments
 (0)